{
  "openapi": "3.0.3",
  "paths": {
    "/agent-meta/worker-sizes": {
      "get": {
        "tags": [
          "Agent Meta"
        ],
        "summary": "Get Worker sizes from the deployment catalog",
        "parameters": [],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "label": {
                        "type": "string",
                        "minLength": 1
                      },
                      "value": {
                        "type": "object",
                        "properties": {
                          "requests": {
                            "type": "object",
                            "properties": {
                              "cpu": {
                                "type": "string",
                                "pattern": "^\\d+(?:\\.\\d+)?m?$"
                              },
                              "memory": {
                                "type": "string",
                                "pattern": "^[1-9]\\d*(?:Mi|Gi)$"
                              }
                            },
                            "required": [
                              "cpu",
                              "memory"
                            ],
                            "additionalProperties": false
                          },
                          "limits": {
                            "type": "object",
                            "properties": {
                              "cpu": {
                                "type": "string",
                                "pattern": "^\\d+(?:\\.\\d+)?m?$"
                              },
                              "memory": {
                                "type": "string",
                                "pattern": "^[1-9]\\d*(?:Mi|Gi)$"
                              }
                            },
                            "required": [
                              "cpu",
                              "memory"
                            ],
                            "additionalProperties": false
                          }
                        },
                        "required": [
                          "requests",
                          "limits"
                        ],
                        "additionalProperties": false
                      },
                      "id": {
                        "type": "string",
                        "minLength": 1
                      },
                      "runtimeClassName": {
                        "type": "string",
                        "enum": [
                          "kata-xxsmall",
                          "kata-xsmall",
                          "kata-small",
                          "kata-medium",
                          "kata-large",
                          "kata-xlarge",
                          "kata-xxlarge"
                        ]
                      }
                    },
                    "required": [
                      "label",
                      "value",
                      "id",
                      "runtimeClassName"
                    ],
                    "additionalProperties": false
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agent-meta/sizes": {
      "get": {
        "tags": [
          "Agent Meta"
        ],
        "summary": "Get a list of available agent sizes",
        "parameters": [
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "label": {
                        "type": "string"
                      },
                      "value": {
                        "type": "object",
                        "properties": {
                          "requests": {
                            "type": "object",
                            "properties": {
                              "memory": {
                                "type": "string",
                                "pattern": "^(\\d+(?:\\.\\d+)?)([mMgGkK]?i?)$"
                              },
                              "cpu": {
                                "type": "string",
                                "pattern": "^(\\d+(?:\\.\\d+)?)([mMgGkK]?i?)$"
                              }
                            },
                            "additionalProperties": false
                          },
                          "limits": {
                            "type": "object",
                            "properties": {
                              "memory": {
                                "type": "string",
                                "pattern": "^(\\d+(?:\\.\\d+)?)([mMgGkK]?i?)$"
                              },
                              "cpu": {
                                "type": "string",
                                "pattern": "^(\\d+(?:\\.\\d+)?)([mMgGkK]?i?)$"
                              }
                            },
                            "additionalProperties": false
                          }
                        },
                        "additionalProperties": false
                      },
                      "id": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "label",
                      "value",
                      "id"
                    ],
                    "additionalProperties": false
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agent-meta/image-tags": {
      "get": {
        "tags": [
          "Agent Meta"
        ],
        "summary": "Get a list of available agent image tags",
        "parameters": [
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agent-meta/npm-whitelist": {
      "get": {
        "tags": [
          "Agent Meta"
        ],
        "summary": "Get a list of whitelisted npm packages",
        "parameters": [
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agents": {
      "post": {
        "tags": [
          "Agents"
        ],
        "summary": "Create an agent",
        "parameters": [
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "customDomain": {
                            "type": "string",
                            "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                          },
                          "type": {
                            "type": "string",
                            "const": "worker"
                          },
                          "worker": {
                            "type": "string",
                            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                          },
                          "workerVersion": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "runtimeClassName": {
                            "type": "string",
                            "enum": [
                              "kata-xxsmall",
                              "kata-xsmall",
                              "kata-small",
                              "kata-medium",
                              "kata-large",
                              "kata-xlarge",
                              "kata-xxlarge"
                            ]
                          },
                          "schedule": {
                            "type": "string",
                            "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                          },
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "default": "cpu",
                            "type": "string",
                            "const": "cpu"
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "targetCpu": {
                            "type": "number",
                            "minimum": 1,
                            "maximum": 100
                          }
                        },
                        "required": [
                          "name",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "worker",
                          "workerVersion",
                          "runtimeClassName",
                          "maxReplicas",
                          "scaleType",
                          "minReplicas",
                          "targetCpu"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "customDomain": {
                            "type": "string",
                            "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                          },
                          "type": {
                            "type": "string",
                            "const": "worker"
                          },
                          "worker": {
                            "type": "string",
                            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                          },
                          "workerVersion": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "runtimeClassName": {
                            "type": "string",
                            "enum": [
                              "kata-xxsmall",
                              "kata-xsmall",
                              "kata-small",
                              "kata-medium",
                              "kata-large",
                              "kata-xlarge",
                              "kata-xxlarge"
                            ]
                          },
                          "schedule": {
                            "type": "string",
                            "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                          },
                          "maxReplicas": {
                            "default": 1,
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "pollingInterval": {
                            "default": 20,
                            "type": "integer",
                            "minimum": 5,
                            "maximum": 9007199254740991
                          },
                          "minReplicas": {
                            "default": 0,
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 100
                          },
                          "cooldownPeriod": {
                            "default": 5,
                            "type": "number",
                            "minimum": 0
                          },
                          "lagThreshold": {
                            "default": 100,
                            "type": "number",
                            "minimum": 2
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "lag"
                          }
                        },
                        "required": [
                          "name",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "worker",
                          "workerVersion",
                          "runtimeClassName",
                          "maxReplicas",
                          "pollingInterval",
                          "minReplicas",
                          "cooldownPeriod",
                          "lagThreshold",
                          "scaleType"
                        ],
                        "additionalProperties": false
                      }
                    ]
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "processingType": {
                            "default": "ordered",
                            "type": "string",
                            "enum": [
                              "ordered",
                              "unordered"
                            ]
                          },
                          "type": {
                            "type": "string",
                            "const": "nos-topic"
                          },
                          "ruleset": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "processingType",
                          "type",
                          "ruleset",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "processingType": {
                            "default": "ordered",
                            "type": "string",
                            "enum": [
                              "ordered",
                              "unordered"
                            ]
                          },
                          "type": {
                            "type": "string",
                            "const": "flow-topic"
                          },
                          "flow": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "processingType",
                          "type",
                          "flow",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "type": {
                        "type": "string",
                        "const": "flow-cron"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "entryPoint": {
                        "type": "string"
                      },
                      "schedule": {
                        "type": "string",
                        "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                      }
                    },
                    "required": [
                      "name",
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "flow",
                      "entryPoint",
                      "schedule"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "type": {
                            "type": "string",
                            "const": "chat-topic"
                          },
                          "flow": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "flow",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "flow-http"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "maxReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "scaleType": {
                        "default": "cpu",
                        "type": "string",
                        "const": "cpu"
                      },
                      "minReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "targetCpu": {
                        "type": "number",
                        "minimum": 1,
                        "maximum": 100
                      }
                    },
                    "required": [
                      "name",
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "flow",
                      "maxReplicas",
                      "scaleType",
                      "minReplicas",
                      "targetCpu"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "site-http"
                      },
                      "site": {
                        "type": "string"
                      },
                      "ref": {
                        "type": "string"
                      },
                      "maxReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "scaleType": {
                        "default": "cpu",
                        "type": "string",
                        "const": "cpu"
                      },
                      "minReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "targetCpu": {
                        "type": "number",
                        "minimum": 1,
                        "maximum": 100
                      }
                    },
                    "required": [
                      "name",
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "site",
                      "ref",
                      "maxReplicas",
                      "scaleType",
                      "minReplicas",
                      "targetCpu"
                    ],
                    "additionalProperties": false
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Agent"
                }
              }
            }
          },
          "400": {
            "description": "Invalid payload provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Agents"
        ],
        "summary": "Perform bulk actions on agents",
        "parameters": [
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "type": "object",
                    "properties": {
                      "action": {
                        "type": "string",
                        "const": "start"
                      },
                      "ids": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                        }
                      }
                    },
                    "required": [
                      "action"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "action": {
                        "type": "string",
                        "const": "stop"
                      },
                      "reason": {
                        "type": "string"
                      },
                      "ids": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                        }
                      }
                    },
                    "required": [
                      "action"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "action": {
                        "type": "string",
                        "const": "restart"
                      },
                      "ids": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                        }
                      }
                    },
                    "required": [
                      "action"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "action": {
                        "type": "string",
                        "const": "set-log-level"
                      },
                      "ids": {
                        "type": "array",
                        "items": {
                          "type": "string",
                          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                        }
                      },
                      "level": {
                        "type": "string",
                        "enum": [
                          "fatal",
                          "error",
                          "warn",
                          "info",
                          "debug"
                        ]
                      },
                      "durationMs": {
                        "type": "number"
                      }
                    },
                    "required": [
                      "action",
                      "level",
                      "durationMs"
                    ],
                    "additionalProperties": false
                  }
                ],
                "type": "object"
              }
            }
          }
        },
        "responses": {
          "204": {
            "description": "Action completed",
            "content": {}
          },
          "400": {
            "description": "Invalid payload provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent(s) not found",
            "content": {}
          }
        }
      }
    },
    "/[\\$]event/agents": {
      "post": {
        "tags": [
          "Agents"
        ],
        "summary": "Runs post create event",
        "parameters": [
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "customDomain": {
                            "type": "string",
                            "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                          },
                          "type": {
                            "type": "string",
                            "const": "worker"
                          },
                          "worker": {
                            "type": "string",
                            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                          },
                          "workerVersion": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "runtimeClassName": {
                            "type": "string",
                            "enum": [
                              "kata-xxsmall",
                              "kata-xsmall",
                              "kata-small",
                              "kata-medium",
                              "kata-large",
                              "kata-xlarge",
                              "kata-xxlarge"
                            ]
                          },
                          "schedule": {
                            "type": "string",
                            "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                          },
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "default": "cpu",
                            "type": "string",
                            "const": "cpu"
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "targetCpu": {
                            "type": "number",
                            "minimum": 1,
                            "maximum": 100
                          }
                        },
                        "required": [
                          "name",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "worker",
                          "workerVersion",
                          "runtimeClassName",
                          "maxReplicas",
                          "scaleType",
                          "minReplicas",
                          "targetCpu"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "customDomain": {
                            "type": "string",
                            "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                          },
                          "type": {
                            "type": "string",
                            "const": "worker"
                          },
                          "worker": {
                            "type": "string",
                            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                          },
                          "workerVersion": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "runtimeClassName": {
                            "type": "string",
                            "enum": [
                              "kata-xxsmall",
                              "kata-xsmall",
                              "kata-small",
                              "kata-medium",
                              "kata-large",
                              "kata-xlarge",
                              "kata-xxlarge"
                            ]
                          },
                          "schedule": {
                            "type": "string",
                            "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                          },
                          "maxReplicas": {
                            "default": 1,
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "pollingInterval": {
                            "default": 20,
                            "type": "integer",
                            "minimum": 5,
                            "maximum": 9007199254740991
                          },
                          "minReplicas": {
                            "default": 0,
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 100
                          },
                          "cooldownPeriod": {
                            "default": 5,
                            "type": "number",
                            "minimum": 0
                          },
                          "lagThreshold": {
                            "default": 100,
                            "type": "number",
                            "minimum": 2
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "lag"
                          }
                        },
                        "required": [
                          "name",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "worker",
                          "workerVersion",
                          "runtimeClassName",
                          "maxReplicas",
                          "pollingInterval",
                          "minReplicas",
                          "cooldownPeriod",
                          "lagThreshold",
                          "scaleType"
                        ],
                        "additionalProperties": false
                      }
                    ]
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "processingType": {
                            "default": "ordered",
                            "type": "string",
                            "enum": [
                              "ordered",
                              "unordered"
                            ]
                          },
                          "type": {
                            "type": "string",
                            "const": "nos-topic"
                          },
                          "ruleset": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "processingType",
                          "type",
                          "ruleset",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "processingType": {
                            "default": "ordered",
                            "type": "string",
                            "enum": [
                              "ordered",
                              "unordered"
                            ]
                          },
                          "type": {
                            "type": "string",
                            "const": "flow-topic"
                          },
                          "flow": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "processingType",
                          "type",
                          "flow",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "type": {
                        "type": "string",
                        "const": "flow-cron"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "entryPoint": {
                        "type": "string"
                      },
                      "schedule": {
                        "type": "string",
                        "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                      }
                    },
                    "required": [
                      "name",
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "flow",
                      "entryPoint",
                      "schedule"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "type": {
                            "type": "string",
                            "const": "chat-topic"
                          },
                          "flow": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "flow",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "flow-http"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "maxReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "scaleType": {
                        "default": "cpu",
                        "type": "string",
                        "const": "cpu"
                      },
                      "minReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "targetCpu": {
                        "type": "number",
                        "minimum": 1,
                        "maximum": 100
                      }
                    },
                    "required": [
                      "name",
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "flow",
                      "maxReplicas",
                      "scaleType",
                      "minReplicas",
                      "targetCpu"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "site-http"
                      },
                      "site": {
                        "type": "string"
                      },
                      "ref": {
                        "type": "string"
                      },
                      "maxReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "scaleType": {
                        "default": "cpu",
                        "type": "string",
                        "const": "cpu"
                      },
                      "minReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "targetCpu": {
                        "type": "number",
                        "minimum": 1,
                        "maximum": 100
                      }
                    },
                    "required": [
                      "name",
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "site",
                      "ref",
                      "maxReplicas",
                      "scaleType",
                      "minReplicas",
                      "targetCpu"
                    ],
                    "additionalProperties": false
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Event sent",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agents/{agentId}": {
      "put": {
        "tags": [
          "Agents"
        ],
        "summary": "Update agent by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "customDomain": {
                            "type": "string",
                            "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                          },
                          "type": {
                            "type": "string",
                            "const": "worker"
                          },
                          "worker": {
                            "type": "string",
                            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                          },
                          "workerVersion": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "runtimeClassName": {
                            "type": "string",
                            "enum": [
                              "kata-xxsmall",
                              "kata-xsmall",
                              "kata-small",
                              "kata-medium",
                              "kata-large",
                              "kata-xlarge",
                              "kata-xxlarge"
                            ]
                          },
                          "schedule": {
                            "type": "string",
                            "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                          },
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "default": "cpu",
                            "type": "string",
                            "const": "cpu"
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "targetCpu": {
                            "type": "number",
                            "minimum": 1,
                            "maximum": 100
                          }
                        },
                        "required": [
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "worker",
                          "workerVersion",
                          "runtimeClassName",
                          "maxReplicas",
                          "scaleType",
                          "minReplicas",
                          "targetCpu"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "customDomain": {
                            "type": "string",
                            "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                          },
                          "type": {
                            "type": "string",
                            "const": "worker"
                          },
                          "worker": {
                            "type": "string",
                            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                          },
                          "workerVersion": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "runtimeClassName": {
                            "type": "string",
                            "enum": [
                              "kata-xxsmall",
                              "kata-xsmall",
                              "kata-small",
                              "kata-medium",
                              "kata-large",
                              "kata-xlarge",
                              "kata-xxlarge"
                            ]
                          },
                          "schedule": {
                            "type": "string",
                            "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                          },
                          "maxReplicas": {
                            "default": 1,
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "pollingInterval": {
                            "default": 20,
                            "type": "integer",
                            "minimum": 5,
                            "maximum": 9007199254740991
                          },
                          "minReplicas": {
                            "default": 0,
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 100
                          },
                          "cooldownPeriod": {
                            "default": 5,
                            "type": "number",
                            "minimum": 0
                          },
                          "lagThreshold": {
                            "default": 100,
                            "type": "number",
                            "minimum": 2
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "lag"
                          }
                        },
                        "required": [
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "worker",
                          "workerVersion",
                          "runtimeClassName",
                          "maxReplicas",
                          "pollingInterval",
                          "minReplicas",
                          "cooldownPeriod",
                          "lagThreshold",
                          "scaleType"
                        ],
                        "additionalProperties": false
                      }
                    ]
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "processingType": {
                            "default": "ordered",
                            "type": "string",
                            "enum": [
                              "ordered",
                              "unordered"
                            ]
                          },
                          "type": {
                            "type": "string",
                            "const": "nos-topic"
                          },
                          "ruleset": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "processingType",
                          "type",
                          "ruleset",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "processingType": {
                            "default": "ordered",
                            "type": "string",
                            "enum": [
                              "ordered",
                              "unordered"
                            ]
                          },
                          "type": {
                            "type": "string",
                            "const": "flow-topic"
                          },
                          "flow": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "processingType",
                          "type",
                          "flow",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "type": {
                        "type": "string",
                        "const": "flow-cron"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "entryPoint": {
                        "type": "string"
                      },
                      "schedule": {
                        "type": "string",
                        "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                      }
                    },
                    "required": [
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "flow",
                      "entryPoint",
                      "schedule"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "type": {
                            "type": "string",
                            "const": "chat-topic"
                          },
                          "flow": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "flow",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "flow-http"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "maxReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "scaleType": {
                        "type": "string",
                        "const": "cpu"
                      },
                      "minReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "targetCpu": {
                        "type": "number",
                        "minimum": 1,
                        "maximum": 100
                      }
                    },
                    "required": [
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "flow",
                      "maxReplicas",
                      "scaleType",
                      "minReplicas",
                      "targetCpu"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "site-http"
                      },
                      "site": {
                        "type": "string"
                      },
                      "ref": {
                        "type": "string"
                      },
                      "maxReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "scaleType": {
                        "type": "string",
                        "const": "cpu"
                      },
                      "minReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "targetCpu": {
                        "type": "number",
                        "minimum": 1,
                        "maximum": 100
                      }
                    },
                    "required": [
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "site",
                      "ref",
                      "maxReplicas",
                      "scaleType",
                      "minReplicas",
                      "targetCpu"
                    ],
                    "additionalProperties": false
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Agent"
                }
              }
            }
          },
          "400": {
            "description": "Invalid payload provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      },
      "delete": {
        "tags": [
          "Agents"
        ],
        "summary": "Delete agent by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "204": {
            "description": "Agent deleted successfully",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/[\\$]event/agents/{agentId}": {
      "put": {
        "tags": [
          "Agents"
        ],
        "summary": "Update agent by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "anyOf": [
                  {
                    "anyOf": [
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "customDomain": {
                            "type": "string",
                            "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                          },
                          "type": {
                            "type": "string",
                            "const": "worker"
                          },
                          "worker": {
                            "type": "string",
                            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                          },
                          "workerVersion": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "runtimeClassName": {
                            "type": "string",
                            "enum": [
                              "kata-xxsmall",
                              "kata-xsmall",
                              "kata-small",
                              "kata-medium",
                              "kata-large",
                              "kata-xlarge",
                              "kata-xxlarge"
                            ]
                          },
                          "schedule": {
                            "type": "string",
                            "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                          },
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "default": "cpu",
                            "type": "string",
                            "const": "cpu"
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "targetCpu": {
                            "type": "number",
                            "minimum": 1,
                            "maximum": 100
                          }
                        },
                        "required": [
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "worker",
                          "workerVersion",
                          "runtimeClassName",
                          "maxReplicas",
                          "scaleType",
                          "minReplicas",
                          "targetCpu"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "customDomain": {
                            "type": "string",
                            "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                          },
                          "type": {
                            "type": "string",
                            "const": "worker"
                          },
                          "worker": {
                            "type": "string",
                            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                          },
                          "workerVersion": {
                            "type": "integer",
                            "exclusiveMinimum": 0,
                            "maximum": 9007199254740991
                          },
                          "runtimeClassName": {
                            "type": "string",
                            "enum": [
                              "kata-xxsmall",
                              "kata-xsmall",
                              "kata-small",
                              "kata-medium",
                              "kata-large",
                              "kata-xlarge",
                              "kata-xxlarge"
                            ]
                          },
                          "schedule": {
                            "type": "string",
                            "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                          },
                          "maxReplicas": {
                            "default": 1,
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "pollingInterval": {
                            "default": 20,
                            "type": "integer",
                            "minimum": 5,
                            "maximum": 9007199254740991
                          },
                          "minReplicas": {
                            "default": 0,
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 100
                          },
                          "cooldownPeriod": {
                            "default": 5,
                            "type": "number",
                            "minimum": 0
                          },
                          "lagThreshold": {
                            "default": 100,
                            "type": "number",
                            "minimum": 2
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "lag"
                          }
                        },
                        "required": [
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "worker",
                          "workerVersion",
                          "runtimeClassName",
                          "maxReplicas",
                          "pollingInterval",
                          "minReplicas",
                          "cooldownPeriod",
                          "lagThreshold",
                          "scaleType"
                        ],
                        "additionalProperties": false
                      }
                    ]
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "processingType": {
                            "default": "ordered",
                            "type": "string",
                            "enum": [
                              "ordered",
                              "unordered"
                            ]
                          },
                          "type": {
                            "type": "string",
                            "const": "nos-topic"
                          },
                          "ruleset": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "processingType",
                          "type",
                          "ruleset",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "processingType": {
                            "default": "ordered",
                            "type": "string",
                            "enum": [
                              "ordered",
                              "unordered"
                            ]
                          },
                          "type": {
                            "type": "string",
                            "const": "flow-topic"
                          },
                          "flow": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "processingType",
                          "type",
                          "flow",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "type": {
                        "type": "string",
                        "const": "flow-cron"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "entryPoint": {
                        "type": "string"
                      },
                      "schedule": {
                        "type": "string",
                        "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                      }
                    },
                    "required": [
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "flow",
                      "entryPoint",
                      "schedule"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "allOf": [
                      {
                        "type": "object",
                        "properties": {
                          "description": {
                            "type": "string"
                          },
                          "image": {
                            "type": "string",
                            "pattern": "^\\d+\\.\\d+\\.\\d+"
                          },
                          "displayName": {
                            "type": "string"
                          },
                          "envVars": {
                            "type": "array",
                            "items": {
                              "type": "object",
                              "properties": {
                                "label": {
                                  "type": "string"
                                },
                                "value": {
                                  "type": "string"
                                }
                              },
                              "required": [
                                "label",
                                "value"
                              ],
                              "additionalProperties": false
                            }
                          },
                          "size": {
                            "type": "string"
                          },
                          "configName": {
                            "type": "string"
                          },
                          "livenessTimeoutSeconds": {
                            "default": 50,
                            "type": "integer",
                            "minimum": 50,
                            "maximum": 3600,
                            "multipleOf": 10
                          },
                          "type": {
                            "type": "string",
                            "const": "chat-topic"
                          },
                          "flow": {
                            "type": "string"
                          },
                          "entryPoint": {
                            "default": "",
                            "type": "string"
                          }
                        },
                        "required": [
                          "image",
                          "displayName",
                          "size",
                          "livenessTimeoutSeconds",
                          "type",
                          "flow",
                          "entryPoint"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "oneOf": [
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "cpu"
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "targetCpu": {
                                "type": "number",
                                "minimum": 1,
                                "maximum": 100
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "minReplicas",
                              "targetCpu"
                            ],
                            "additionalProperties": false
                          },
                          {
                            "type": "object",
                            "properties": {
                              "maxReplicas": {
                                "type": "integer",
                                "minimum": 1,
                                "maximum": 100
                              },
                              "scaleType": {
                                "type": "string",
                                "const": "lag"
                              },
                              "pollingInterval": {
                                "default": 60,
                                "type": "number",
                                "minimum": 15
                              },
                              "minReplicas": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 100
                              },
                              "cooldownPeriod": {
                                "default": 5,
                                "type": "number",
                                "minimum": 0
                              },
                              "lagThreshold": {
                                "default": 100,
                                "type": "number",
                                "minimum": 2
                              }
                            },
                            "required": [
                              "maxReplicas",
                              "scaleType",
                              "pollingInterval",
                              "minReplicas",
                              "cooldownPeriod",
                              "lagThreshold"
                            ],
                            "additionalProperties": false
                          }
                        ],
                        "type": "object"
                      }
                    ]
                  },
                  {
                    "type": "object",
                    "properties": {
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "flow-http"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "maxReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "scaleType": {
                        "type": "string",
                        "const": "cpu"
                      },
                      "minReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "targetCpu": {
                        "type": "number",
                        "minimum": 1,
                        "maximum": 100
                      }
                    },
                    "required": [
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "flow",
                      "maxReplicas",
                      "scaleType",
                      "minReplicas",
                      "targetCpu"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "site-http"
                      },
                      "site": {
                        "type": "string"
                      },
                      "ref": {
                        "type": "string"
                      },
                      "maxReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "scaleType": {
                        "type": "string",
                        "const": "cpu"
                      },
                      "minReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "targetCpu": {
                        "type": "number",
                        "minimum": 1,
                        "maximum": 100
                      }
                    },
                    "required": [
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "site",
                      "ref",
                      "maxReplicas",
                      "scaleType",
                      "minReplicas",
                      "targetCpu"
                    ],
                    "additionalProperties": false
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Event not required",
            "content": {}
          },
          "202": {
            "description": "Event sent",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agents/{agentId}/lag": {
      "get": {
        "tags": [
          "Agents"
        ],
        "summary": "Get logs topic backlog",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "lag": {
                      "type": "number"
                    },
                    "partitions": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "partition": {
                            "type": "number"
                          },
                          "lag": {
                            "type": "number"
                          }
                        },
                        "required": [
                          "partition",
                          "lag"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "lag",
                    "partitions"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Agents"
        ],
        "summary": "Clears the logs topic backlog",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "responses": {
          "204": {
            "description": "Backlog cleared",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agents/{agentId}/backlog": {
      "get": {
        "tags": [
          "Agents"
        ],
        "summary": "Get logs topic backlog",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "lag": {
                      "type": "number"
                    },
                    "partitions": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "partition": {
                            "type": "number"
                          },
                          "lag": {
                            "type": "number"
                          }
                        },
                        "required": [
                          "partition",
                          "lag"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "lag",
                    "partitions"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Agents"
        ],
        "summary": "Clears the logs topic backlog",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "responses": {
          "204": {
            "description": "Backlog cleared",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agents/{agentId}/custom-domain": {
      "get": {
        "tags": [
          "Agents"
        ],
        "summary": "Get agent custom domain status by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "configured": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "configured"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Agent not valid",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/agents/{agentId}/validate-custom-domain": {
      "post": {
        "tags": [
          "Agents"
        ],
        "summary": "Validate agent custom domain by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "valid": {
                      "type": "boolean"
                    }
                  },
                  "required": [
                    "valid"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "400": {
            "description": "Agent not valid",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/agents/{agentId}/start": {
      "post": {
        "tags": [
          "Agents"
        ],
        "summary": "Start agent by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "204": {
            "description": "Agent starting",
            "content": {}
          },
          "400": {
            "description": "Agent not stopped",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/agents/{agentId}/stop": {
      "post": {
        "tags": [
          "Agents"
        ],
        "summary": "Stop agent by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "204": {
            "description": "Agent stopping",
            "content": {}
          },
          "400": {
            "description": "Agent not started",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/agents/{agentId}/restart": {
      "post": {
        "tags": [
          "Agents"
        ],
        "summary": "Restart agent by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "204": {
            "description": "Agent restarting",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/agents/{agentId}/manual-run": {
      "post": {
        "tags": [
          "Agents"
        ],
        "summary": "Run agent manually by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "202": {
            "description": "Agent manual run queued",
            "content": {}
          },
          "400": {
            "description": "Agent stopped or type not supported for manual run",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/agents/{agentId}/log-level": {
      "put": {
        "tags": [
          "Agents"
        ],
        "summary": "Set the log level of an agent by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "level": {
                    "type": "string",
                    "enum": [
                      "fatal",
                      "error",
                      "warn",
                      "info",
                      "debug"
                    ]
                  },
                  "durationMs": {
                    "type": "number"
                  }
                },
                "required": [
                  "level",
                  "durationMs"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "Agent log level is being set",
            "content": {}
          },
          "400": {
            "description": "Invalid payload provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      },
      "get": {
        "tags": [
          "Agents"
        ],
        "summary": "Get the stored log level of an agent by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "level": {
                      "type": "string",
                      "enum": [
                        "fatal",
                        "error",
                        "warn",
                        "info",
                        "debug"
                      ]
                    },
                    "durationMs": {
                      "type": "number"
                    }
                  },
                  "required": [
                    "level",
                    "durationMs"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "204": {
            "description": "Agent doesn't have custom log level",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/agents/{agentId}/log-levels": {
      "get": {
        "tags": [
          "Agents"
        ],
        "summary": "Get the log level of agent pods by id",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "object",
                    "properties": {
                      "logLevel": {
                        "type": "string",
                        "enum": [
                          "fatal",
                          "error",
                          "warn",
                          "info",
                          "debug"
                        ]
                      },
                      "pod": {
                        "type": "string"
                      }
                    },
                    "required": [
                      "logLevel",
                      "pod"
                    ],
                    "additionalProperties": false
                  }
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/agents/lint/{flowId}": {
      "get": {
        "tags": [
          "Agents"
        ],
        "summary": "Get flow lint messages",
        "parameters": [
          {
            "name": "flowId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "application/json",
            "content": {}
          },
          "400": {
            "description": "Invalid parameters provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Flow not found",
            "content": {}
          }
        }
      }
    },
    "/agents/{agentId}/crash-logs": {
      "get": {
        "tags": [
          "Crash Logs"
        ],
        "summary": "Get crash logs",
        "parameters": [
          {
            "name": "includeTotal",
            "in": "query"
          },
          {
            "name": "pageSize",
            "in": "query"
          },
          {
            "name": "pageToken",
            "in": "query"
          },
          {
            "name": "agentId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "items": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/CrashLog"
                      }
                    },
                    "nextPageToken": {
                      "type": "string"
                    },
                    "totalCount": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid search provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      },
      "post": {
        "tags": [
          "Crash Logs"
        ],
        "summary": "Create a crash log",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "hostname": {
                    "type": "string"
                  },
                  "message": {
                    "type": "string"
                  },
                  "error": {}
                },
                "required": [
                  "hostname",
                  "message"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/CrashLog"
                }
              }
            }
          },
          "400": {
            "description": "Invalid payload provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Agent not found",
            "content": {}
          }
        }
      }
    },
    "/$page/agents/{agentId}/crash-logs": {
      "post": {
        "tags": [
          "Crash Logs"
        ],
        "summary": "Page crash logs",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/$ListQuery"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "items": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/CrashLog"
                      }
                    },
                    "nextPageToken": {
                      "type": "string"
                    },
                    "totalCount": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid search provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agents/{agentId}/pods/{id}": {
      "get": {
        "tags": [
          "Pods"
        ],
        "summary": "Get pod",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "items": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Pod"
                      }
                    },
                    "nextPageToken": {
                      "type": "string"
                    },
                    "totalCount": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid search provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Pods"
        ],
        "summary": "Delete pod by id",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "204": {
            "description": "Pod deleted successfully",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Pod not found",
            "content": {}
          }
        }
      }
    },
    "/agents/{agentId}/pods/{id}/runner-status": {
      "get": {
        "tags": [
          "Pods"
        ],
        "summary": "Get pod",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true
          },
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "items": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Pod"
                      }
                    },
                    "nextPageToken": {
                      "type": "string"
                    },
                    "totalCount": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid search provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agents/{agentId}/pods": {
      "get": {
        "tags": [
          "Pods"
        ],
        "summary": "Get pods",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "items": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Pod"
                      }
                    },
                    "nextPageToken": {
                      "type": "string"
                    },
                    "totalCount": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid search provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/pods": {
      "get": {
        "tags": [
          "Pods"
        ],
        "summary": "Get all pods",
        "parameters": [
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "items": {
                      "type": "array",
                      "items": {
                        "$ref": "#/components/schemas/Pod"
                      }
                    },
                    "nextPageToken": {
                      "type": "string"
                    },
                    "totalCount": {
                      "type": "integer"
                    }
                  },
                  "required": [
                    "items"
                  ]
                }
              }
            }
          },
          "400": {
            "description": "Invalid search provided",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/agents/{agentId}/instances": {
      "get": {
        "tags": [
          "Pods"
        ],
        "summary": "Get agent instances",
        "parameters": [
          {
            "name": "agentId",
            "in": "path",
            "required": true
          },
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "items": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "name": {
                            "type": "string"
                          },
                          "status": {
                            "type": "string"
                          },
                          "createdAt": {
                            "type": "string"
                          },
                          "startedAt": {
                            "type": "string"
                          }
                        },
                        "required": [
                          "name",
                          "status",
                          "createdAt"
                        ],
                        "additionalProperties": false
                      }
                    }
                  },
                  "required": [
                    "items"
                  ],
                  "additionalProperties": false
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/workers/{workerId}/logs": {
      "get": {
        "tags": [
          "Workers"
        ],
        "summary": "Stream a Worker's container logs",
        "parameters": [
          {
            "name": "tail",
            "in": "query",
            "description": "only the last lines of each container"
          },
          {
            "name": "since",
            "in": "query",
            "description": "only lines newer than this duration, e.g. 10m"
          },
          {
            "name": "previous",
            "in": "query",
            "description": "each container's previous run"
          },
          {
            "name": "follow",
            "in": "query",
            "description": "keep streaming, including containers that start later"
          },
          {
            "name": "container",
            "in": "query",
            "description": "only these containers, repeated for more; by default every container except the network gate"
          },
          {
            "name": "workerId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "responses": {
          "200": {
            "description": "Server-sent events: `line` { pod, container, time, line }, `notice` { pod, container, message }, then `end` { message? }",
            "content": {}
          },
          "400": {
            "description": "Invalid query, or a container the Worker's pods don't have",
            "content": {}
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Worker not found",
            "content": {}
          }
        }
      }
    },
    "/workers": {
      "post": {
        "tags": [
          "Workers"
        ],
        "summary": "Validate and pin a new Worker before persistence",
        "parameters": [
          {
            "name": "x-org-id",
            "in": "header",
            "required": false
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1
                  },
                  "description": {
                    "type": "string"
                  },
                  "size": {
                    "type": "string",
                    "minLength": 1
                  },
                  "minReplicas": {
                    "default": 1,
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "maxReplicas": {
                    "default": 1,
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "targetCpu": {
                    "default": 80,
                    "type": "number",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "envVars": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "label": {
                          "type": "string"
                        },
                        "value": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "label",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "customDomain": {
                    "type": "string",
                    "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                  },
                  "schedule": {
                    "type": "string",
                    "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                  },
                  "image": {
                    "type": "string"
                  },
                  "compose": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "services": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "maxLength": 63,
                          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                        },
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "image": {
                              "type": "string"
                            },
                            "command": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            "entrypoint": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            "environment": {
                              "type": "object",
                              "propertyNames": {
                                "type": "string",
                                "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                              },
                              "additionalProperties": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "ports": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "target": {
                                    "type": "integer",
                                    "minimum": 1,
                                    "maximum": 65535
                                  },
                                  "published": {
                                    "type": "string"
                                  },
                                  "protocol": {
                                    "type": "string",
                                    "const": "tcp"
                                  },
                                  "mode": {
                                    "type": "string",
                                    "const": "ingress"
                                  }
                                },
                                "required": [
                                  "target"
                                ],
                                "additionalProperties": false,
                                "patternProperties": {
                                  "^x-": {}
                                }
                              }
                            },
                            "expose": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "^\\d{1,5}(\\/tcp)?$"
                              }
                            },
                            "depends_on": {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {
                                "type": "object",
                                "properties": {
                                  "condition": {
                                    "type": "string",
                                    "enum": [
                                      "service_started",
                                      "service_healthy",
                                      "service_completed_successfully"
                                    ]
                                  },
                                  "required": {
                                    "type": "boolean",
                                    "const": true
                                  },
                                  "restart": {
                                    "type": "boolean",
                                    "const": false
                                  }
                                },
                                "required": [
                                  "condition"
                                ],
                                "additionalProperties": false,
                                "patternProperties": {
                                  "^x-": {}
                                }
                              }
                            },
                            "healthcheck": {
                              "type": "object",
                              "properties": {
                                "test": {
                                  "minItems": 1,
                                  "maxItems": 64,
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  }
                                },
                                "interval": {
                                  "type": "string"
                                },
                                "timeout": {
                                  "type": "string"
                                },
                                "retries": {
                                  "type": "integer",
                                  "minimum": 1,
                                  "maximum": 120
                                },
                                "start_period": {
                                  "type": "string"
                                },
                                "start_interval": {
                                  "type": "string"
                                },
                                "disable": {
                                  "type": "boolean"
                                }
                              },
                              "additionalProperties": false,
                              "patternProperties": {
                                "^x-": {}
                              }
                            },
                            "volumes": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "type": {
                                    "type": "string",
                                    "const": "volume"
                                  },
                                  "source": {
                                    "type": "string"
                                  },
                                  "target": {
                                    "type": "string",
                                    "format": "starts_with",
                                    "pattern": "^\\/.*"
                                  },
                                  "read_only": {
                                    "type": "boolean"
                                  },
                                  "volume": {
                                    "type": "object",
                                    "properties": {
                                      "nocopy": {
                                        "type": "boolean",
                                        "const": true
                                      },
                                      "subpath": {
                                        "type": "string",
                                        "pattern": "^(?!.*(?:^|\\/)\\.{1,2}(?:\\/|$))[^/][^\\\\]*$"
                                      }
                                    },
                                    "additionalProperties": false,
                                    "patternProperties": {
                                      "^x-": {}
                                    }
                                  }
                                },
                                "required": [
                                  "type",
                                  "source",
                                  "target"
                                ],
                                "additionalProperties": false,
                                "patternProperties": {
                                  "^x-": {}
                                }
                              }
                            },
                            "configs": {
                              "type": "array",
                              "items": {
                                "anyOf": [
                                  {
                                    "type": "string",
                                    "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "source": {
                                        "type": "string",
                                        "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                                      },
                                      "target": {
                                        "type": "string",
                                        "minLength": 1
                                      },
                                      "mode": {
                                        "type": "integer",
                                        "minimum": 0,
                                        "maximum": 511
                                      }
                                    },
                                    "required": [
                                      "source"
                                    ],
                                    "additionalProperties": false,
                                    "patternProperties": {
                                      "^x-": {}
                                    }
                                  }
                                ]
                              }
                            },
                            "secrets": {
                              "type": "array",
                              "items": {
                                "anyOf": [
                                  {
                                    "type": "string",
                                    "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "source": {
                                        "type": "string",
                                        "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                                      },
                                      "target": {
                                        "type": "string",
                                        "minLength": 1
                                      },
                                      "mode": {
                                        "type": "integer",
                                        "minimum": 0,
                                        "maximum": 511
                                      }
                                    },
                                    "required": [
                                      "source"
                                    ],
                                    "additionalProperties": false,
                                    "patternProperties": {
                                      "^x-": {}
                                    }
                                  }
                                ]
                              }
                            },
                            "working_dir": {
                              "type": "string",
                              "format": "starts_with",
                              "pattern": "^\\/.*"
                            },
                            "networks": {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {
                                "type": "null"
                              }
                            },
                            "x-contextual": {
                              "type": "object",
                              "properties": {
                                "public": {
                                  "anyOf": [
                                    {
                                      "type": "boolean"
                                    },
                                    {
                                      "type": "integer",
                                      "minimum": 1,
                                      "maximum": 65535
                                    }
                                  ]
                                },
                                "container_type": {
                                  "type": "string",
                                  "enum": [
                                    "primary",
                                    "sidecar",
                                    "init"
                                  ]
                                },
                                "http_healthcheck": {
                                  "type": "object",
                                  "properties": {
                                    "path": {
                                      "type": "string",
                                      "maxLength": 2048,
                                      "format": "starts_with",
                                      "pattern": "^\\/.*"
                                    },
                                    "port": {
                                      "type": "integer",
                                      "minimum": 1024,
                                      "maximum": 65535
                                    }
                                  },
                                  "required": [
                                    "path",
                                    "port"
                                  ],
                                  "additionalProperties": false
                                },
                                "features": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "enum": [
                                      "messaging",
                                      "native-object-api",
                                      "logging",
                                      "platform-services",
                                      "messaging-producer",
                                      "keda"
                                    ]
                                  }
                                },
                                "scaling": {
                                  "type": "object",
                                  "properties": {
                                    "maxReplicas": {
                                      "default": 1,
                                      "type": "integer",
                                      "minimum": 1,
                                      "maximum": 100
                                    },
                                    "pollingInterval": {
                                      "default": 20,
                                      "type": "integer",
                                      "minimum": 5,
                                      "maximum": 9007199254740991
                                    },
                                    "minReplicas": {
                                      "default": 0,
                                      "type": "integer",
                                      "minimum": 0,
                                      "maximum": 100
                                    },
                                    "cooldownPeriod": {
                                      "default": 5,
                                      "type": "number",
                                      "minimum": 0
                                    },
                                    "lagThreshold": {
                                      "default": 100,
                                      "type": "number",
                                      "minimum": 2
                                    }
                                  },
                                  "required": [
                                    "maxReplicas",
                                    "pollingInterval",
                                    "minReplicas",
                                    "cooldownPeriod",
                                    "lagThreshold"
                                  ],
                                  "additionalProperties": false
                                }
                              },
                              "additionalProperties": false,
                              "patternProperties": {
                                "^x-": {}
                              }
                            }
                          },
                          "required": [
                            "image"
                          ],
                          "additionalProperties": false,
                          "patternProperties": {
                            "^x-": {}
                          }
                        }
                      },
                      "volumes": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "maxLength": 63,
                          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                        },
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string"
                            }
                          },
                          "additionalProperties": false,
                          "patternProperties": {
                            "^x-": {}
                          }
                        }
                      },
                      "configs": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                        },
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "content": {
                              "type": "string"
                            },
                            "name": {
                              "type": "string"
                            },
                            "file": {
                              "not": {}
                            },
                            "environment": {
                              "not": {}
                            }
                          },
                          "required": [
                            "content"
                          ],
                          "additionalProperties": false,
                          "patternProperties": {
                            "^x-": {}
                          }
                        }
                      },
                      "secrets": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                        },
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "environment": {
                              "type": "string",
                              "pattern": "^[A-Z_][A-Z0-9_]*$"
                            },
                            "name": {
                              "type": "string"
                            },
                            "file": {
                              "not": {}
                            }
                          },
                          "required": [
                            "environment"
                          ],
                          "additionalProperties": false,
                          "patternProperties": {
                            "^x-": {}
                          }
                        }
                      },
                      "networks": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {}
                      },
                      "x-contextual": {
                        "type": "object",
                        "properties": {
                          "version": {
                            "type": "number",
                            "const": 1
                          }
                        },
                        "required": [
                          "version"
                        ],
                        "additionalProperties": false,
                        "patternProperties": {
                          "^x-": {}
                        }
                      }
                    },
                    "required": [
                      "services",
                      "x-contextual"
                    ],
                    "additionalProperties": false,
                    "patternProperties": {
                      "^x-": {}
                    }
                  },
                  "managed": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string",
                        "maxLength": 128,
                        "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                      },
                      "version": {
                        "type": "string",
                        "pattern": "^[A-Za-z0-9_][A-Za-z0-9_.-]{0,127}$"
                      },
                      "options": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "maxLength": 4096
                        }
                      },
                      "digest": {
                        "type": "string",
                        "pattern": "^sha256:[a-f0-9]{64}$"
                      }
                    },
                    "required": [
                      "name",
                      "version"
                    ],
                    "additionalProperties": false
                  },
                  "template": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string",
                        "maxLength": 128,
                        "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                      },
                      "version": {
                        "type": "string",
                        "pattern": "^[A-Za-z0-9_][A-Za-z0-9_.-]{0,127}$"
                      },
                      "options": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "maxLength": 4096
                        }
                      },
                      "digest": {
                        "type": "string",
                        "pattern": "^sha256:[a-f0-9]{64}$"
                      }
                    },
                    "required": [
                      "name",
                      "version"
                    ],
                    "additionalProperties": false
                  },
                  "id": {
                    "type": "string",
                    "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                  }
                },
                "required": [
                  "name",
                  "size",
                  "minReplicas",
                  "maxReplicas",
                  "targetCpu",
                  "id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Worker"
                }
              }
            }
          },
          "400": {
            "description": "Invalid Worker configuration",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "402": {
            "description": "Agent plan limit exceeded",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Worker not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "503": {
            "description": "Worker deployment dependency unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/workers/{workerId}": {
      "put": {
        "tags": [
          "Workers"
        ],
        "summary": "Validate and pin an updated Worker before persistence",
        "parameters": [
          {
            "name": "workerId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string",
                    "minLength": 1
                  },
                  "description": {
                    "type": "string"
                  },
                  "size": {
                    "type": "string",
                    "minLength": 1
                  },
                  "minReplicas": {
                    "default": 1,
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "maxReplicas": {
                    "default": 1,
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "targetCpu": {
                    "default": 80,
                    "type": "number",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "envVars": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "label": {
                          "type": "string"
                        },
                        "value": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "label",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "customDomain": {
                    "type": "string",
                    "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                  },
                  "schedule": {
                    "type": "string",
                    "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                  },
                  "image": {
                    "type": "string"
                  },
                  "compose": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "services": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "maxLength": 63,
                          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                        },
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "image": {
                              "type": "string"
                            },
                            "command": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            "entrypoint": {
                              "type": "array",
                              "items": {
                                "type": "string"
                              }
                            },
                            "environment": {
                              "type": "object",
                              "propertyNames": {
                                "type": "string",
                                "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                              },
                              "additionalProperties": {
                                "type": [
                                  "string",
                                  "null"
                                ]
                              }
                            },
                            "ports": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "target": {
                                    "type": "integer",
                                    "minimum": 1,
                                    "maximum": 65535
                                  },
                                  "published": {
                                    "type": "string"
                                  },
                                  "protocol": {
                                    "type": "string",
                                    "const": "tcp"
                                  },
                                  "mode": {
                                    "type": "string",
                                    "const": "ingress"
                                  }
                                },
                                "required": [
                                  "target"
                                ],
                                "additionalProperties": false,
                                "patternProperties": {
                                  "^x-": {}
                                }
                              }
                            },
                            "expose": {
                              "type": "array",
                              "items": {
                                "type": "string",
                                "pattern": "^\\d{1,5}(\\/tcp)?$"
                              }
                            },
                            "depends_on": {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {
                                "type": "object",
                                "properties": {
                                  "condition": {
                                    "type": "string",
                                    "enum": [
                                      "service_started",
                                      "service_healthy",
                                      "service_completed_successfully"
                                    ]
                                  },
                                  "required": {
                                    "type": "boolean",
                                    "const": true
                                  },
                                  "restart": {
                                    "type": "boolean",
                                    "const": false
                                  }
                                },
                                "required": [
                                  "condition"
                                ],
                                "additionalProperties": false,
                                "patternProperties": {
                                  "^x-": {}
                                }
                              }
                            },
                            "healthcheck": {
                              "type": "object",
                              "properties": {
                                "test": {
                                  "minItems": 1,
                                  "maxItems": 64,
                                  "type": "array",
                                  "items": {
                                    "type": "string"
                                  }
                                },
                                "interval": {
                                  "type": "string"
                                },
                                "timeout": {
                                  "type": "string"
                                },
                                "retries": {
                                  "type": "integer",
                                  "minimum": 1,
                                  "maximum": 120
                                },
                                "start_period": {
                                  "type": "string"
                                },
                                "start_interval": {
                                  "type": "string"
                                },
                                "disable": {
                                  "type": "boolean"
                                }
                              },
                              "additionalProperties": false,
                              "patternProperties": {
                                "^x-": {}
                              }
                            },
                            "volumes": {
                              "type": "array",
                              "items": {
                                "type": "object",
                                "properties": {
                                  "type": {
                                    "type": "string",
                                    "const": "volume"
                                  },
                                  "source": {
                                    "type": "string"
                                  },
                                  "target": {
                                    "type": "string",
                                    "format": "starts_with",
                                    "pattern": "^\\/.*"
                                  },
                                  "read_only": {
                                    "type": "boolean"
                                  },
                                  "volume": {
                                    "type": "object",
                                    "properties": {
                                      "nocopy": {
                                        "type": "boolean",
                                        "const": true
                                      },
                                      "subpath": {
                                        "type": "string",
                                        "pattern": "^(?!.*(?:^|\\/)\\.{1,2}(?:\\/|$))[^/][^\\\\]*$"
                                      }
                                    },
                                    "additionalProperties": false,
                                    "patternProperties": {
                                      "^x-": {}
                                    }
                                  }
                                },
                                "required": [
                                  "type",
                                  "source",
                                  "target"
                                ],
                                "additionalProperties": false,
                                "patternProperties": {
                                  "^x-": {}
                                }
                              }
                            },
                            "configs": {
                              "type": "array",
                              "items": {
                                "anyOf": [
                                  {
                                    "type": "string",
                                    "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "source": {
                                        "type": "string",
                                        "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                                      },
                                      "target": {
                                        "type": "string",
                                        "minLength": 1
                                      },
                                      "mode": {
                                        "type": "integer",
                                        "minimum": 0,
                                        "maximum": 511
                                      }
                                    },
                                    "required": [
                                      "source"
                                    ],
                                    "additionalProperties": false,
                                    "patternProperties": {
                                      "^x-": {}
                                    }
                                  }
                                ]
                              }
                            },
                            "secrets": {
                              "type": "array",
                              "items": {
                                "anyOf": [
                                  {
                                    "type": "string",
                                    "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                                  },
                                  {
                                    "type": "object",
                                    "properties": {
                                      "source": {
                                        "type": "string",
                                        "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                                      },
                                      "target": {
                                        "type": "string",
                                        "minLength": 1
                                      },
                                      "mode": {
                                        "type": "integer",
                                        "minimum": 0,
                                        "maximum": 511
                                      }
                                    },
                                    "required": [
                                      "source"
                                    ],
                                    "additionalProperties": false,
                                    "patternProperties": {
                                      "^x-": {}
                                    }
                                  }
                                ]
                              }
                            },
                            "working_dir": {
                              "type": "string",
                              "format": "starts_with",
                              "pattern": "^\\/.*"
                            },
                            "networks": {
                              "type": "object",
                              "propertyNames": {
                                "type": "string"
                              },
                              "additionalProperties": {
                                "type": "null"
                              }
                            },
                            "x-contextual": {
                              "type": "object",
                              "properties": {
                                "public": {
                                  "anyOf": [
                                    {
                                      "type": "boolean"
                                    },
                                    {
                                      "type": "integer",
                                      "minimum": 1,
                                      "maximum": 65535
                                    }
                                  ]
                                },
                                "container_type": {
                                  "type": "string",
                                  "enum": [
                                    "primary",
                                    "sidecar",
                                    "init"
                                  ]
                                },
                                "http_healthcheck": {
                                  "type": "object",
                                  "properties": {
                                    "path": {
                                      "type": "string",
                                      "maxLength": 2048,
                                      "format": "starts_with",
                                      "pattern": "^\\/.*"
                                    },
                                    "port": {
                                      "type": "integer",
                                      "minimum": 1024,
                                      "maximum": 65535
                                    }
                                  },
                                  "required": [
                                    "path",
                                    "port"
                                  ],
                                  "additionalProperties": false
                                },
                                "features": {
                                  "type": "array",
                                  "items": {
                                    "type": "string",
                                    "enum": [
                                      "messaging",
                                      "native-object-api",
                                      "logging",
                                      "platform-services",
                                      "messaging-producer",
                                      "keda"
                                    ]
                                  }
                                },
                                "scaling": {
                                  "type": "object",
                                  "properties": {
                                    "maxReplicas": {
                                      "default": 1,
                                      "type": "integer",
                                      "minimum": 1,
                                      "maximum": 100
                                    },
                                    "pollingInterval": {
                                      "default": 20,
                                      "type": "integer",
                                      "minimum": 5,
                                      "maximum": 9007199254740991
                                    },
                                    "minReplicas": {
                                      "default": 0,
                                      "type": "integer",
                                      "minimum": 0,
                                      "maximum": 100
                                    },
                                    "cooldownPeriod": {
                                      "default": 5,
                                      "type": "number",
                                      "minimum": 0
                                    },
                                    "lagThreshold": {
                                      "default": 100,
                                      "type": "number",
                                      "minimum": 2
                                    }
                                  },
                                  "required": [
                                    "maxReplicas",
                                    "pollingInterval",
                                    "minReplicas",
                                    "cooldownPeriod",
                                    "lagThreshold"
                                  ],
                                  "additionalProperties": false
                                }
                              },
                              "additionalProperties": false,
                              "patternProperties": {
                                "^x-": {}
                              }
                            }
                          },
                          "required": [
                            "image"
                          ],
                          "additionalProperties": false,
                          "patternProperties": {
                            "^x-": {}
                          }
                        }
                      },
                      "volumes": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "maxLength": 63,
                          "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                        },
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "name": {
                              "type": "string"
                            }
                          },
                          "additionalProperties": false,
                          "patternProperties": {
                            "^x-": {}
                          }
                        }
                      },
                      "configs": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                        },
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "content": {
                              "type": "string"
                            },
                            "name": {
                              "type": "string"
                            },
                            "file": {
                              "not": {}
                            },
                            "environment": {
                              "not": {}
                            }
                          },
                          "required": [
                            "content"
                          ],
                          "additionalProperties": false,
                          "patternProperties": {
                            "^x-": {}
                          }
                        }
                      },
                      "secrets": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                        },
                        "additionalProperties": {
                          "type": "object",
                          "properties": {
                            "environment": {
                              "type": "string",
                              "pattern": "^[A-Z_][A-Z0-9_]*$"
                            },
                            "name": {
                              "type": "string"
                            },
                            "file": {
                              "not": {}
                            }
                          },
                          "required": [
                            "environment"
                          ],
                          "additionalProperties": false,
                          "patternProperties": {
                            "^x-": {}
                          }
                        }
                      },
                      "networks": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string"
                        },
                        "additionalProperties": {}
                      },
                      "x-contextual": {
                        "type": "object",
                        "properties": {
                          "version": {
                            "type": "number",
                            "const": 1
                          }
                        },
                        "required": [
                          "version"
                        ],
                        "additionalProperties": false,
                        "patternProperties": {
                          "^x-": {}
                        }
                      }
                    },
                    "required": [
                      "services",
                      "x-contextual"
                    ],
                    "additionalProperties": false,
                    "patternProperties": {
                      "^x-": {}
                    }
                  },
                  "managed": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string",
                        "maxLength": 128,
                        "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                      },
                      "version": {
                        "type": "string",
                        "pattern": "^[A-Za-z0-9_][A-Za-z0-9_.-]{0,127}$"
                      },
                      "options": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "maxLength": 4096
                        }
                      },
                      "digest": {
                        "type": "string",
                        "pattern": "^sha256:[a-f0-9]{64}$"
                      }
                    },
                    "required": [
                      "name",
                      "version"
                    ],
                    "additionalProperties": false
                  },
                  "template": {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string",
                        "maxLength": 128,
                        "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                      },
                      "version": {
                        "type": "string",
                        "pattern": "^[A-Za-z0-9_][A-Za-z0-9_.-]{0,127}$"
                      },
                      "options": {
                        "type": "object",
                        "propertyNames": {
                          "type": "string",
                          "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                        },
                        "additionalProperties": {
                          "type": "string",
                          "maxLength": 4096
                        }
                      },
                      "digest": {
                        "type": "string",
                        "pattern": "^sha256:[a-f0-9]{64}$"
                      }
                    },
                    "required": [
                      "name",
                      "version"
                    ],
                    "additionalProperties": false
                  }
                },
                "required": [
                  "name",
                  "size",
                  "minReplicas",
                  "maxReplicas",
                  "targetCpu"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/Worker"
                }
              }
            }
          },
          "400": {
            "description": "Invalid Worker configuration",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "402": {
            "description": "Agent plan limit exceeded",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Worker not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "503": {
            "description": "Worker deployment dependency unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      },
      "delete": {
        "tags": [
          "Workers"
        ],
        "summary": "Validate Worker deletion before persistence",
        "parameters": [
          {
            "name": "workerId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "responses": {
          "204": {
            "description": "Worker deletion validated",
            "content": {}
          },
          "400": {
            "description": "Invalid Worker configuration",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "402": {
            "description": "Agent plan limit exceeded",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Worker not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "503": {
            "description": "Worker deployment dependency unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/[\\$]event/workers/{workerId}": {
      "delete": {
        "tags": [
          "Workers"
        ],
        "summary": "Remove the underlying Agent after Worker deletion",
        "parameters": [
          {
            "name": "workerId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "responses": {
          "204": {
            "description": "Worker deployment removed",
            "content": {}
          },
          "400": {
            "description": "Invalid Worker configuration",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "402": {
            "description": "Agent plan limit exceeded",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Worker not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "409": {
            "description": "Worker exists again; deletion refused",
            "content": {}
          },
          "503": {
            "description": "Worker deployment dependency unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      },
      "put": {
        "tags": [
          "Workers"
        ],
        "summary": "Deploy an updated Worker revision",
        "parameters": [
          {
            "name": "workerId",
            "in": "path",
            "required": true
          }
        ],
        "deprecated": false,
        "responses": {
          "202": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkerDeploymentAgent"
                }
              }
            }
          },
          "400": {
            "description": "Invalid Worker configuration",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "402": {
            "description": "Agent plan limit exceeded",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Worker not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "503": {
            "description": "Worker deployment dependency unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    },
    "/[\\$]event/workers": {
      "post": {
        "tags": [
          "Workers"
        ],
        "summary": "Deploy a newly persisted Worker",
        "parameters": [],
        "deprecated": false,
        "requestBody": {
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string",
                    "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                  }
                },
                "required": [
                  "id"
                ],
                "additionalProperties": false
              }
            }
          }
        },
        "responses": {
          "202": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/WorkerDeploymentAgent"
                }
              }
            }
          },
          "400": {
            "description": "Invalid Worker configuration",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid authorization header",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "402": {
            "description": "Agent plan limit exceeded",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "403": {
            "description": "Invalid permissions",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "404": {
            "description": "Worker not found",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          },
          "503": {
            "description": "Worker deployment dependency unavailable",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/$ErrorResponse"
                }
              }
            }
          }
        }
      }
    }
  },
  "security": [
    {
      "jwt": []
    }
  ],
  "components": {
    "schemas": {
      "$ListQuery": {
        "type": "object",
        "properties": {
          "pageToken": {
            "type": "string",
            "minLength": 1
          },
          "orderBy": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            ]
          },
          "fields": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "array",
                "items": {
                  "type": "string"
                }
              }
            ]
          },
          "pageSize": {
            "type": "integer",
            "minimum": 0,
            "maximum": 9007199254740991
          },
          "includeTotal": {
            "type": "boolean"
          },
          "filterMode": {
            "anyOf": [
              {
                "type": "string",
                "const": "AND"
              },
              {
                "type": "string",
                "const": "OR"
              }
            ]
          }
        },
        "additionalProperties": false
      },
      "$ErrorResponse": {
        "type": "object",
        "properties": {
          "code": {
            "type": [
              "string",
              "number"
            ]
          },
          "message": {
            "type": "string"
          },
          "errors": {
            "type": "array",
            "items": {}
          }
        },
        "required": [
          "code",
          "message"
        ],
        "additionalProperties": false
      },
      "Agent": {
        "allOf": [
          {
            "anyOf": [
              {
                "anyOf": [
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "worker"
                      },
                      "worker": {
                        "type": "string",
                        "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                      },
                      "workerVersion": {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      },
                      "runtimeClassName": {
                        "type": "string",
                        "enum": [
                          "kata-xxsmall",
                          "kata-xsmall",
                          "kata-small",
                          "kata-medium",
                          "kata-large",
                          "kata-xlarge",
                          "kata-xxlarge"
                        ]
                      },
                      "schedule": {
                        "type": "string",
                        "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                      },
                      "maxReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "scaleType": {
                        "default": "cpu",
                        "type": "string",
                        "const": "cpu"
                      },
                      "minReplicas": {
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "targetCpu": {
                        "type": "number",
                        "minimum": 1,
                        "maximum": 100
                      }
                    },
                    "required": [
                      "name",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "worker",
                      "workerVersion",
                      "runtimeClassName",
                      "maxReplicas",
                      "scaleType",
                      "minReplicas",
                      "targetCpu"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "customDomain": {
                        "type": "string",
                        "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                      },
                      "type": {
                        "type": "string",
                        "const": "worker"
                      },
                      "worker": {
                        "type": "string",
                        "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                      },
                      "workerVersion": {
                        "type": "integer",
                        "exclusiveMinimum": 0,
                        "maximum": 9007199254740991
                      },
                      "runtimeClassName": {
                        "type": "string",
                        "enum": [
                          "kata-xxsmall",
                          "kata-xsmall",
                          "kata-small",
                          "kata-medium",
                          "kata-large",
                          "kata-xlarge",
                          "kata-xxlarge"
                        ]
                      },
                      "schedule": {
                        "type": "string",
                        "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                      },
                      "maxReplicas": {
                        "default": 1,
                        "type": "integer",
                        "minimum": 1,
                        "maximum": 100
                      },
                      "pollingInterval": {
                        "default": 20,
                        "type": "integer",
                        "minimum": 5,
                        "maximum": 9007199254740991
                      },
                      "minReplicas": {
                        "default": 0,
                        "type": "integer",
                        "minimum": 0,
                        "maximum": 100
                      },
                      "cooldownPeriod": {
                        "default": 5,
                        "type": "number",
                        "minimum": 0
                      },
                      "lagThreshold": {
                        "default": 100,
                        "type": "number",
                        "minimum": 2
                      },
                      "scaleType": {
                        "type": "string",
                        "const": "lag"
                      }
                    },
                    "required": [
                      "name",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "worker",
                      "workerVersion",
                      "runtimeClassName",
                      "maxReplicas",
                      "pollingInterval",
                      "minReplicas",
                      "cooldownPeriod",
                      "lagThreshold",
                      "scaleType"
                    ],
                    "additionalProperties": false
                  }
                ]
              },
              {
                "allOf": [
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "processingType": {
                        "default": "ordered",
                        "type": "string",
                        "enum": [
                          "ordered",
                          "unordered"
                        ]
                      },
                      "type": {
                        "type": "string",
                        "const": "nos-topic"
                      },
                      "ruleset": {
                        "type": "string"
                      },
                      "entryPoint": {
                        "default": "",
                        "type": "string"
                      }
                    },
                    "required": [
                      "name",
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "processingType",
                      "type",
                      "ruleset",
                      "entryPoint"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "oneOf": [
                      {
                        "type": "object",
                        "properties": {
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "cpu"
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "targetCpu": {
                            "type": "number",
                            "minimum": 1,
                            "maximum": 100
                          }
                        },
                        "required": [
                          "maxReplicas",
                          "scaleType",
                          "minReplicas",
                          "targetCpu"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "lag"
                          },
                          "pollingInterval": {
                            "default": 60,
                            "type": "number",
                            "minimum": 15
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 100
                          },
                          "cooldownPeriod": {
                            "default": 5,
                            "type": "number",
                            "minimum": 0
                          },
                          "lagThreshold": {
                            "default": 100,
                            "type": "number",
                            "minimum": 2
                          }
                        },
                        "required": [
                          "maxReplicas",
                          "scaleType",
                          "pollingInterval",
                          "minReplicas",
                          "cooldownPeriod",
                          "lagThreshold"
                        ],
                        "additionalProperties": false
                      }
                    ],
                    "type": "object"
                  }
                ]
              },
              {
                "allOf": [
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "processingType": {
                        "default": "ordered",
                        "type": "string",
                        "enum": [
                          "ordered",
                          "unordered"
                        ]
                      },
                      "type": {
                        "type": "string",
                        "const": "flow-topic"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "entryPoint": {
                        "default": "",
                        "type": "string"
                      }
                    },
                    "required": [
                      "name",
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "processingType",
                      "type",
                      "flow",
                      "entryPoint"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "oneOf": [
                      {
                        "type": "object",
                        "properties": {
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "cpu"
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "targetCpu": {
                            "type": "number",
                            "minimum": 1,
                            "maximum": 100
                          }
                        },
                        "required": [
                          "maxReplicas",
                          "scaleType",
                          "minReplicas",
                          "targetCpu"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "lag"
                          },
                          "pollingInterval": {
                            "default": 60,
                            "type": "number",
                            "minimum": 15
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 100
                          },
                          "cooldownPeriod": {
                            "default": 5,
                            "type": "number",
                            "minimum": 0
                          },
                          "lagThreshold": {
                            "default": 100,
                            "type": "number",
                            "minimum": 2
                          }
                        },
                        "required": [
                          "maxReplicas",
                          "scaleType",
                          "pollingInterval",
                          "minReplicas",
                          "cooldownPeriod",
                          "lagThreshold"
                        ],
                        "additionalProperties": false
                      }
                    ],
                    "type": "object"
                  }
                ]
              },
              {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "description": {
                    "type": "string"
                  },
                  "image": {
                    "type": "string",
                    "pattern": "^\\d+\\.\\d+\\.\\d+"
                  },
                  "displayName": {
                    "type": "string"
                  },
                  "envVars": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "label": {
                          "type": "string"
                        },
                        "value": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "label",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "size": {
                    "type": "string"
                  },
                  "configName": {
                    "type": "string"
                  },
                  "livenessTimeoutSeconds": {
                    "default": 50,
                    "type": "integer",
                    "minimum": 50,
                    "maximum": 3600,
                    "multipleOf": 10
                  },
                  "type": {
                    "type": "string",
                    "const": "flow-cron"
                  },
                  "flow": {
                    "type": "string"
                  },
                  "entryPoint": {
                    "type": "string"
                  },
                  "schedule": {
                    "type": "string",
                    "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
                  }
                },
                "required": [
                  "name",
                  "image",
                  "displayName",
                  "size",
                  "livenessTimeoutSeconds",
                  "type",
                  "flow",
                  "entryPoint",
                  "schedule"
                ],
                "additionalProperties": false
              },
              {
                "allOf": [
                  {
                    "type": "object",
                    "properties": {
                      "name": {
                        "type": "string"
                      },
                      "description": {
                        "type": "string"
                      },
                      "image": {
                        "type": "string",
                        "pattern": "^\\d+\\.\\d+\\.\\d+"
                      },
                      "displayName": {
                        "type": "string"
                      },
                      "envVars": {
                        "type": "array",
                        "items": {
                          "type": "object",
                          "properties": {
                            "label": {
                              "type": "string"
                            },
                            "value": {
                              "type": "string"
                            }
                          },
                          "required": [
                            "label",
                            "value"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "size": {
                        "type": "string"
                      },
                      "configName": {
                        "type": "string"
                      },
                      "livenessTimeoutSeconds": {
                        "default": 50,
                        "type": "integer",
                        "minimum": 50,
                        "maximum": 3600,
                        "multipleOf": 10
                      },
                      "type": {
                        "type": "string",
                        "const": "chat-topic"
                      },
                      "flow": {
                        "type": "string"
                      },
                      "entryPoint": {
                        "default": "",
                        "type": "string"
                      }
                    },
                    "required": [
                      "name",
                      "image",
                      "displayName",
                      "size",
                      "livenessTimeoutSeconds",
                      "type",
                      "flow",
                      "entryPoint"
                    ],
                    "additionalProperties": false
                  },
                  {
                    "oneOf": [
                      {
                        "type": "object",
                        "properties": {
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "cpu"
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "targetCpu": {
                            "type": "number",
                            "minimum": 1,
                            "maximum": 100
                          }
                        },
                        "required": [
                          "maxReplicas",
                          "scaleType",
                          "minReplicas",
                          "targetCpu"
                        ],
                        "additionalProperties": false
                      },
                      {
                        "type": "object",
                        "properties": {
                          "maxReplicas": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 100
                          },
                          "scaleType": {
                            "type": "string",
                            "const": "lag"
                          },
                          "pollingInterval": {
                            "default": 60,
                            "type": "number",
                            "minimum": 15
                          },
                          "minReplicas": {
                            "type": "integer",
                            "minimum": 0,
                            "maximum": 100
                          },
                          "cooldownPeriod": {
                            "default": 5,
                            "type": "number",
                            "minimum": 0
                          },
                          "lagThreshold": {
                            "default": 100,
                            "type": "number",
                            "minimum": 2
                          }
                        },
                        "required": [
                          "maxReplicas",
                          "scaleType",
                          "pollingInterval",
                          "minReplicas",
                          "cooldownPeriod",
                          "lagThreshold"
                        ],
                        "additionalProperties": false
                      }
                    ],
                    "type": "object"
                  }
                ]
              },
              {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "description": {
                    "type": "string"
                  },
                  "image": {
                    "type": "string",
                    "pattern": "^\\d+\\.\\d+\\.\\d+"
                  },
                  "displayName": {
                    "type": "string"
                  },
                  "envVars": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "label": {
                          "type": "string"
                        },
                        "value": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "label",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "size": {
                    "type": "string"
                  },
                  "configName": {
                    "type": "string"
                  },
                  "livenessTimeoutSeconds": {
                    "default": 50,
                    "type": "integer",
                    "minimum": 50,
                    "maximum": 3600,
                    "multipleOf": 10
                  },
                  "customDomain": {
                    "type": "string",
                    "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                  },
                  "type": {
                    "type": "string",
                    "const": "flow-http"
                  },
                  "flow": {
                    "type": "string"
                  },
                  "maxReplicas": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "scaleType": {
                    "default": "cpu",
                    "type": "string",
                    "const": "cpu"
                  },
                  "minReplicas": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "targetCpu": {
                    "type": "number",
                    "minimum": 1,
                    "maximum": 100
                  }
                },
                "required": [
                  "name",
                  "image",
                  "displayName",
                  "size",
                  "livenessTimeoutSeconds",
                  "type",
                  "flow",
                  "maxReplicas",
                  "scaleType",
                  "minReplicas",
                  "targetCpu"
                ],
                "additionalProperties": false
              },
              {
                "type": "object",
                "properties": {
                  "name": {
                    "type": "string"
                  },
                  "description": {
                    "type": "string"
                  },
                  "image": {
                    "type": "string",
                    "pattern": "^\\d+\\.\\d+\\.\\d+"
                  },
                  "displayName": {
                    "type": "string"
                  },
                  "envVars": {
                    "type": "array",
                    "items": {
                      "type": "object",
                      "properties": {
                        "label": {
                          "type": "string"
                        },
                        "value": {
                          "type": "string"
                        }
                      },
                      "required": [
                        "label",
                        "value"
                      ],
                      "additionalProperties": false
                    }
                  },
                  "size": {
                    "type": "string"
                  },
                  "configName": {
                    "type": "string"
                  },
                  "livenessTimeoutSeconds": {
                    "default": 50,
                    "type": "integer",
                    "minimum": 50,
                    "maximum": 3600,
                    "multipleOf": 10
                  },
                  "customDomain": {
                    "type": "string",
                    "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
                  },
                  "type": {
                    "type": "string",
                    "const": "site-http"
                  },
                  "site": {
                    "type": "string"
                  },
                  "ref": {
                    "type": "string"
                  },
                  "maxReplicas": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "scaleType": {
                    "default": "cpu",
                    "type": "string",
                    "const": "cpu"
                  },
                  "minReplicas": {
                    "type": "integer",
                    "minimum": 1,
                    "maximum": 100
                  },
                  "targetCpu": {
                    "type": "number",
                    "minimum": 1,
                    "maximum": 100
                  }
                },
                "required": [
                  "name",
                  "image",
                  "displayName",
                  "size",
                  "livenessTimeoutSeconds",
                  "type",
                  "site",
                  "ref",
                  "maxReplicas",
                  "scaleType",
                  "minReplicas",
                  "targetCpu"
                ],
                "additionalProperties": false
              }
            ]
          },
          {
            "type": "object",
            "properties": {
              "_metaData": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "createdAt": {
                    "type": "string",
                    "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                    "description": "An ISO 8601 date time string",
                    "format": "date-time"
                  },
                  "updatedAt": {
                    "type": "string",
                    "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                    "description": "An ISO 8601 date time string",
                    "format": "date-time"
                  }
                },
                "required": [
                  "id",
                  "createdAt"
                ],
                "additionalProperties": false
              }
            },
            "required": [
              "_metaData"
            ],
            "additionalProperties": false
          }
        ]
      },
      "CrashLog": {
        "type": "object",
        "properties": {
          "hostname": {
            "type": "string"
          },
          "organizationId": {
            "type": "string"
          },
          "uri": {
            "type": "string"
          },
          "message": {
            "type": "string"
          },
          "error": {},
          "_metaData": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "createdAt": {
                "type": "string",
                "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                "description": "An ISO 8601 date time string",
                "format": "date-time"
              },
              "updatedAt": {
                "type": "string",
                "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                "description": "An ISO 8601 date time string",
                "format": "date-time"
              }
            },
            "required": [
              "id",
              "createdAt"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "hostname",
          "organizationId",
          "uri",
          "message",
          "_metaData"
        ],
        "additionalProperties": false
      },
      "Pod": {
        "type": "object",
        "properties": {
          "metadata": {
            "type": "object",
            "properties": {
              "creationTimestamp": {
                "type": "string"
              },
              "generateName": {
                "type": "string"
              },
              "labels": {
                "type": "object",
                "properties": {
                  "app": {
                    "type": "string"
                  },
                  "pod-template-hash": {
                    "type": "string"
                  }
                },
                "required": [
                  "app",
                  "pod-template-hash"
                ],
                "additionalProperties": false
              },
              "name": {
                "type": "string"
              },
              "ownerReferences": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "apiVersion": {
                      "type": "string"
                    },
                    "blockOwnerDeletion": {
                      "type": "boolean"
                    },
                    "controller": {
                      "type": "boolean"
                    },
                    "kind": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "uid": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "apiVersion",
                    "blockOwnerDeletion",
                    "controller",
                    "kind",
                    "name",
                    "uid"
                  ],
                  "additionalProperties": false
                }
              },
              "resourceVersion": {
                "type": "string"
              },
              "uid": {
                "type": "string"
              }
            },
            "required": [
              "creationTimestamp",
              "generateName",
              "labels",
              "name",
              "ownerReferences",
              "resourceVersion",
              "uid"
            ],
            "additionalProperties": false
          },
          "spec": {
            "type": "object",
            "properties": {
              "dnsPolicy": {
                "type": "string"
              },
              "enableServiceLinks": {
                "type": "boolean"
              },
              "nodeName": {
                "type": "string"
              },
              "nodeSelector": {
                "type": "object",
                "properties": {
                  "agentpool": {
                    "type": "string"
                  }
                },
                "required": [
                  "agentpool"
                ],
                "additionalProperties": false
              },
              "preemptionPolicy": {
                "type": "string"
              },
              "priority": {
                "type": "number"
              },
              "restartPolicy": {
                "type": "string"
              },
              "schedulerName": {
                "type": "string"
              },
              "securityContext": {
                "type": "object",
                "properties": {},
                "additionalProperties": false
              },
              "serviceAccount": {
                "type": "string"
              },
              "serviceAccountName": {
                "type": "string"
              },
              "terminationGracePeriodSeconds": {
                "type": "number"
              }
            },
            "required": [
              "dnsPolicy",
              "enableServiceLinks",
              "nodeName",
              "nodeSelector",
              "preemptionPolicy",
              "priority",
              "restartPolicy",
              "schedulerName",
              "securityContext",
              "serviceAccount",
              "serviceAccountName",
              "terminationGracePeriodSeconds"
            ],
            "additionalProperties": false
          },
          "status": {
            "type": "object",
            "properties": {
              "conditions": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "lastProbeTime": {
                      "type": [
                        "string",
                        "null"
                      ]
                    },
                    "lastTransitionTime": {
                      "type": "string"
                    },
                    "status": {
                      "type": "string"
                    },
                    "type": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "lastProbeTime",
                    "lastTransitionTime",
                    "status",
                    "type"
                  ],
                  "additionalProperties": false
                }
              },
              "phase": {
                "type": "string"
              },
              "qosClass": {
                "type": "string"
              },
              "startTime": {
                "type": "string"
              }
            },
            "required": [
              "conditions",
              "phase",
              "qosClass",
              "startTime"
            ],
            "additionalProperties": false
          },
          "_metaData": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "createdAt": {
                "type": "string",
                "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                "description": "An ISO 8601 date time string",
                "format": "date-time"
              },
              "updatedAt": {
                "type": "string",
                "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                "description": "An ISO 8601 date time string",
                "format": "date-time"
              }
            },
            "required": [
              "id",
              "createdAt"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "metadata",
          "spec",
          "status",
          "_metaData"
        ],
        "additionalProperties": false
      },
      "Worker": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "minLength": 1
          },
          "description": {
            "type": "string"
          },
          "size": {
            "type": "string",
            "minLength": 1
          },
          "minReplicas": {
            "default": 1,
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "maxReplicas": {
            "default": 1,
            "type": "integer",
            "minimum": 1,
            "maximum": 100
          },
          "targetCpu": {
            "default": 80,
            "type": "number",
            "minimum": 1,
            "maximum": 100
          },
          "envVars": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "label": {
                  "type": "string"
                },
                "value": {
                  "type": "string"
                }
              },
              "required": [
                "label",
                "value"
              ],
              "additionalProperties": false
            }
          },
          "customDomain": {
            "type": "string",
            "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
          },
          "schedule": {
            "type": "string",
            "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
          },
          "id": {
            "type": "string",
            "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
          },
          "image": {
            "type": "string",
            "maxLength": 512,
            "pattern": "^[a-z0-9]+(?:[.-][a-z0-9]+)*(?::[0-9]+)?\\/[a-z0-9]+(?:[._/-][a-z0-9]+)*(?::[A-Za-z0-9_][A-Za-z0-9_.-]{0,127})?@sha256:[a-f0-9]{64}$"
          },
          "compose": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "services": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "maxLength": 63,
                  "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                },
                "additionalProperties": {
                  "type": "object",
                  "properties": {
                    "image": {
                      "type": "string"
                    },
                    "command": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "entrypoint": {
                      "type": "array",
                      "items": {
                        "type": "string"
                      }
                    },
                    "environment": {
                      "type": "object",
                      "propertyNames": {
                        "type": "string",
                        "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                      },
                      "additionalProperties": {
                        "type": [
                          "string",
                          "null"
                        ]
                      }
                    },
                    "ports": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "target": {
                            "type": "integer",
                            "minimum": 1,
                            "maximum": 65535
                          },
                          "published": {
                            "type": "string"
                          },
                          "protocol": {
                            "type": "string",
                            "const": "tcp"
                          },
                          "mode": {
                            "type": "string",
                            "const": "ingress"
                          }
                        },
                        "required": [
                          "target"
                        ],
                        "additionalProperties": false,
                        "patternProperties": {
                          "^x-": {}
                        }
                      }
                    },
                    "expose": {
                      "type": "array",
                      "items": {
                        "type": "string",
                        "pattern": "^\\d{1,5}(\\/tcp)?$"
                      }
                    },
                    "depends_on": {
                      "type": "object",
                      "propertyNames": {
                        "type": "string"
                      },
                      "additionalProperties": {
                        "type": "object",
                        "properties": {
                          "condition": {
                            "type": "string",
                            "enum": [
                              "service_started",
                              "service_healthy",
                              "service_completed_successfully"
                            ]
                          },
                          "required": {
                            "type": "boolean",
                            "const": true
                          },
                          "restart": {
                            "type": "boolean",
                            "const": false
                          }
                        },
                        "required": [
                          "condition"
                        ],
                        "additionalProperties": false,
                        "patternProperties": {
                          "^x-": {}
                        }
                      }
                    },
                    "healthcheck": {
                      "type": "object",
                      "properties": {
                        "test": {
                          "minItems": 1,
                          "maxItems": 64,
                          "type": "array",
                          "items": {
                            "type": "string"
                          }
                        },
                        "interval": {
                          "type": "string"
                        },
                        "timeout": {
                          "type": "string"
                        },
                        "retries": {
                          "type": "integer",
                          "minimum": 1,
                          "maximum": 120
                        },
                        "start_period": {
                          "type": "string"
                        },
                        "start_interval": {
                          "type": "string"
                        },
                        "disable": {
                          "type": "boolean"
                        }
                      },
                      "additionalProperties": false,
                      "patternProperties": {
                        "^x-": {}
                      }
                    },
                    "volumes": {
                      "type": "array",
                      "items": {
                        "type": "object",
                        "properties": {
                          "type": {
                            "type": "string",
                            "const": "volume"
                          },
                          "source": {
                            "type": "string"
                          },
                          "target": {
                            "type": "string",
                            "format": "starts_with",
                            "pattern": "^\\/.*"
                          },
                          "read_only": {
                            "type": "boolean"
                          },
                          "volume": {
                            "type": "object",
                            "properties": {
                              "nocopy": {
                                "type": "boolean",
                                "const": true
                              },
                              "subpath": {
                                "type": "string",
                                "pattern": "^(?!.*(?:^|\\/)\\.{1,2}(?:\\/|$))[^/][^\\\\]*$"
                              }
                            },
                            "additionalProperties": false,
                            "patternProperties": {
                              "^x-": {}
                            }
                          }
                        },
                        "required": [
                          "type",
                          "source",
                          "target"
                        ],
                        "additionalProperties": false,
                        "patternProperties": {
                          "^x-": {}
                        }
                      }
                    },
                    "configs": {
                      "type": "array",
                      "items": {
                        "anyOf": [
                          {
                            "type": "string",
                            "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                          },
                          {
                            "type": "object",
                            "properties": {
                              "source": {
                                "type": "string",
                                "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                              },
                              "target": {
                                "type": "string",
                                "minLength": 1
                              },
                              "mode": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 511
                              }
                            },
                            "required": [
                              "source"
                            ],
                            "additionalProperties": false,
                            "patternProperties": {
                              "^x-": {}
                            }
                          }
                        ]
                      }
                    },
                    "secrets": {
                      "type": "array",
                      "items": {
                        "anyOf": [
                          {
                            "type": "string",
                            "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                          },
                          {
                            "type": "object",
                            "properties": {
                              "source": {
                                "type": "string",
                                "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                              },
                              "target": {
                                "type": "string",
                                "minLength": 1
                              },
                              "mode": {
                                "type": "integer",
                                "minimum": 0,
                                "maximum": 511
                              }
                            },
                            "required": [
                              "source"
                            ],
                            "additionalProperties": false,
                            "patternProperties": {
                              "^x-": {}
                            }
                          }
                        ]
                      }
                    },
                    "working_dir": {
                      "type": "string",
                      "format": "starts_with",
                      "pattern": "^\\/.*"
                    },
                    "networks": {
                      "type": "object",
                      "propertyNames": {
                        "type": "string"
                      },
                      "additionalProperties": {
                        "type": "null"
                      }
                    },
                    "x-contextual": {
                      "type": "object",
                      "properties": {
                        "public": {
                          "anyOf": [
                            {
                              "type": "boolean"
                            },
                            {
                              "type": "integer",
                              "minimum": 1,
                              "maximum": 65535
                            }
                          ]
                        },
                        "container_type": {
                          "type": "string",
                          "enum": [
                            "primary",
                            "sidecar",
                            "init"
                          ]
                        },
                        "http_healthcheck": {
                          "type": "object",
                          "properties": {
                            "path": {
                              "type": "string",
                              "maxLength": 2048,
                              "format": "starts_with",
                              "pattern": "^\\/.*"
                            },
                            "port": {
                              "type": "integer",
                              "minimum": 1024,
                              "maximum": 65535
                            }
                          },
                          "required": [
                            "path",
                            "port"
                          ],
                          "additionalProperties": false
                        },
                        "features": {
                          "type": "array",
                          "items": {
                            "type": "string",
                            "enum": [
                              "messaging",
                              "native-object-api",
                              "logging",
                              "platform-services",
                              "messaging-producer",
                              "keda"
                            ]
                          }
                        },
                        "scaling": {
                          "type": "object",
                          "properties": {
                            "maxReplicas": {
                              "default": 1,
                              "type": "integer",
                              "minimum": 1,
                              "maximum": 100
                            },
                            "pollingInterval": {
                              "default": 20,
                              "type": "integer",
                              "minimum": 5,
                              "maximum": 9007199254740991
                            },
                            "minReplicas": {
                              "default": 0,
                              "type": "integer",
                              "minimum": 0,
                              "maximum": 100
                            },
                            "cooldownPeriod": {
                              "default": 5,
                              "type": "number",
                              "minimum": 0
                            },
                            "lagThreshold": {
                              "default": 100,
                              "type": "number",
                              "minimum": 2
                            }
                          },
                          "required": [
                            "maxReplicas",
                            "pollingInterval",
                            "minReplicas",
                            "cooldownPeriod",
                            "lagThreshold"
                          ],
                          "additionalProperties": false
                        }
                      },
                      "additionalProperties": false,
                      "patternProperties": {
                        "^x-": {}
                      }
                    }
                  },
                  "required": [
                    "image"
                  ],
                  "additionalProperties": false,
                  "patternProperties": {
                    "^x-": {}
                  }
                }
              },
              "volumes": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "maxLength": 63,
                  "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
                },
                "additionalProperties": {
                  "type": "object",
                  "properties": {
                    "name": {
                      "type": "string"
                    }
                  },
                  "additionalProperties": false,
                  "patternProperties": {
                    "^x-": {}
                  }
                }
              },
              "configs": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                },
                "additionalProperties": {
                  "type": "object",
                  "properties": {
                    "content": {
                      "type": "string"
                    },
                    "name": {
                      "type": "string"
                    },
                    "file": {
                      "not": {}
                    },
                    "environment": {
                      "not": {}
                    }
                  },
                  "required": [
                    "content"
                  ],
                  "additionalProperties": false,
                  "patternProperties": {
                    "^x-": {}
                  }
                }
              },
              "secrets": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^(?!\\.$)(?!\\.\\.)[A-Za-z0-9._-]{1,253}$"
                },
                "additionalProperties": {
                  "type": "object",
                  "properties": {
                    "environment": {
                      "type": "string",
                      "pattern": "^[A-Z_][A-Z0-9_]*$"
                    },
                    "name": {
                      "type": "string"
                    },
                    "file": {
                      "not": {}
                    }
                  },
                  "required": [
                    "environment"
                  ],
                  "additionalProperties": false,
                  "patternProperties": {
                    "^x-": {}
                  }
                }
              },
              "networks": {
                "type": "object",
                "propertyNames": {
                  "type": "string"
                },
                "additionalProperties": {}
              },
              "x-contextual": {
                "type": "object",
                "properties": {
                  "version": {
                    "type": "number",
                    "const": 1
                  }
                },
                "required": [
                  "version"
                ],
                "additionalProperties": false,
                "patternProperties": {
                  "^x-": {}
                }
              }
            },
            "required": [
              "services",
              "x-contextual"
            ],
            "additionalProperties": false,
            "patternProperties": {
              "^x-": {}
            }
          },
          "managed": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "maxLength": 128,
                "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
              },
              "version": {
                "type": "string",
                "pattern": "^[A-Za-z0-9_][A-Za-z0-9_.-]{0,127}$"
              },
              "options": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                },
                "additionalProperties": {
                  "type": "string",
                  "maxLength": 4096
                }
              },
              "digest": {
                "type": "string",
                "pattern": "^sha256:[a-f0-9]{64}$"
              }
            },
            "required": [
              "name",
              "version",
              "options",
              "digest"
            ],
            "additionalProperties": false
          },
          "template": {
            "type": "object",
            "properties": {
              "name": {
                "type": "string",
                "maxLength": 128,
                "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
              },
              "version": {
                "type": "string",
                "pattern": "^[A-Za-z0-9_][A-Za-z0-9_.-]{0,127}$"
              },
              "options": {
                "type": "object",
                "propertyNames": {
                  "type": "string",
                  "pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
                },
                "additionalProperties": {
                  "type": "string",
                  "maxLength": 4096
                }
              },
              "digest": {
                "type": "string",
                "pattern": "^sha256:[a-f0-9]{64}$"
              }
            },
            "required": [
              "name",
              "version",
              "options",
              "digest"
            ],
            "additionalProperties": false
          },
          "_metaData": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "createdAt": {
                "type": "string",
                "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                "description": "An ISO 8601 date time string",
                "format": "date-time"
              },
              "updatedAt": {
                "type": "string",
                "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                "description": "An ISO 8601 date time string",
                "format": "date-time"
              }
            },
            "required": [
              "id",
              "createdAt"
            ],
            "additionalProperties": false
          }
        },
        "required": [
          "name",
          "size",
          "minReplicas",
          "maxReplicas",
          "targetCpu",
          "id",
          "_metaData"
        ],
        "additionalProperties": false
      },
      "WorkerDeploymentAgent": {
        "anyOf": [
          {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "description": {
                "type": "string"
              },
              "displayName": {
                "type": "string"
              },
              "envVars": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "label",
                    "value"
                  ],
                  "additionalProperties": false
                }
              },
              "size": {
                "type": "string"
              },
              "configName": {
                "type": "string"
              },
              "livenessTimeoutSeconds": {
                "default": 50,
                "type": "integer",
                "minimum": 50,
                "maximum": 3600,
                "multipleOf": 10
              },
              "customDomain": {
                "type": "string",
                "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
              },
              "type": {
                "type": "string",
                "const": "worker"
              },
              "worker": {
                "type": "string",
                "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
              },
              "workerVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "runtimeClassName": {
                "type": "string",
                "enum": [
                  "kata-xxsmall",
                  "kata-xsmall",
                  "kata-small",
                  "kata-medium",
                  "kata-large",
                  "kata-xlarge",
                  "kata-xxlarge"
                ]
              },
              "schedule": {
                "type": "string",
                "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
              },
              "_metaData": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "createdAt": {
                    "type": "string",
                    "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                    "description": "An ISO 8601 date time string",
                    "format": "date-time"
                  },
                  "updatedAt": {
                    "type": "string",
                    "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                    "description": "An ISO 8601 date time string",
                    "format": "date-time"
                  }
                },
                "required": [
                  "id",
                  "createdAt"
                ],
                "additionalProperties": false
              },
              "maxReplicas": {
                "type": "integer",
                "minimum": 1,
                "maximum": 100
              },
              "scaleType": {
                "default": "cpu",
                "type": "string",
                "const": "cpu"
              },
              "minReplicas": {
                "type": "integer",
                "minimum": 1,
                "maximum": 100
              },
              "targetCpu": {
                "type": "number",
                "minimum": 1,
                "maximum": 100
              }
            },
            "required": [
              "name",
              "displayName",
              "size",
              "livenessTimeoutSeconds",
              "type",
              "worker",
              "workerVersion",
              "runtimeClassName",
              "_metaData",
              "maxReplicas",
              "scaleType",
              "minReplicas",
              "targetCpu"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "name": {
                "type": "string"
              },
              "description": {
                "type": "string"
              },
              "displayName": {
                "type": "string"
              },
              "envVars": {
                "type": "array",
                "items": {
                  "type": "object",
                  "properties": {
                    "label": {
                      "type": "string"
                    },
                    "value": {
                      "type": "string"
                    }
                  },
                  "required": [
                    "label",
                    "value"
                  ],
                  "additionalProperties": false
                }
              },
              "size": {
                "type": "string"
              },
              "configName": {
                "type": "string"
              },
              "livenessTimeoutSeconds": {
                "default": 50,
                "type": "integer",
                "minimum": 50,
                "maximum": 3600,
                "multipleOf": 10
              },
              "customDomain": {
                "type": "string",
                "pattern": "^(([a-zA-Z0-9]|[a-zA-Z0-9][a-zA-Z0-9-]*[a-zA-Z0-9])\\.)*([A-Za-z0-9]|[A-Za-z0-9][A-Za-z0-9-]*[A-Za-z0-9])$"
              },
              "type": {
                "type": "string",
                "const": "worker"
              },
              "worker": {
                "type": "string",
                "pattern": "^[a-z0-9]+(?:-[a-z0-9]+)*$"
              },
              "workerVersion": {
                "type": "integer",
                "exclusiveMinimum": 0,
                "maximum": 9007199254740991
              },
              "runtimeClassName": {
                "type": "string",
                "enum": [
                  "kata-xxsmall",
                  "kata-xsmall",
                  "kata-small",
                  "kata-medium",
                  "kata-large",
                  "kata-xlarge",
                  "kata-xxlarge"
                ]
              },
              "schedule": {
                "type": "string",
                "pattern": "^((\\*(\\/\\d+)?|([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?(,([0-5]?\\d)(-([0-5]?\\d)(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?(,([01]?\\d|2[0-3])(-([01]?\\d|2[0-3])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?(,(0?[1-9]|[12]\\d|3[01])(-(0?[1-9]|[12]\\d|3[01])(\\/\\d+)?)?)*)\\s+(\\*(\\/\\d+)?|([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?(,([1-9]|1[012])(-([1-9]|1[012])(\\/\\d+)?)?)*|jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)\\s+(\\*(\\/\\d+)?|([0-6])(-([0-6])(\\/\\d+)?)?(,([0-6])(-([0-6])(\\/\\d+)?)?)*|mon|tue|wed|thu|fri|sat|sun)|(@yearly|@annually|@monthly|@weekly|@daily|@midnight|@hourly))$"
              },
              "_metaData": {
                "type": "object",
                "properties": {
                  "id": {
                    "type": "string"
                  },
                  "createdAt": {
                    "type": "string",
                    "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                    "description": "An ISO 8601 date time string",
                    "format": "date-time"
                  },
                  "updatedAt": {
                    "type": "string",
                    "pattern": "^(?:\\d+(?:\\.\\d+?)?|(?:\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}(?:\\.\\d+)?Z))$",
                    "description": "An ISO 8601 date time string",
                    "format": "date-time"
                  }
                },
                "required": [
                  "id",
                  "createdAt"
                ],
                "additionalProperties": false
              },
              "maxReplicas": {
                "default": 1,
                "type": "integer",
                "minimum": 1,
                "maximum": 100
              },
              "pollingInterval": {
                "default": 20,
                "type": "integer",
                "minimum": 5,
                "maximum": 9007199254740991
              },
              "minReplicas": {
                "default": 0,
                "type": "integer",
                "minimum": 0,
                "maximum": 100
              },
              "cooldownPeriod": {
                "default": 5,
                "type": "number",
                "minimum": 0
              },
              "lagThreshold": {
                "default": 100,
                "type": "number",
                "minimum": 2
              },
              "scaleType": {
                "type": "string",
                "const": "lag"
              }
            },
            "required": [
              "name",
              "displayName",
              "size",
              "livenessTimeoutSeconds",
              "type",
              "worker",
              "workerVersion",
              "runtimeClassName",
              "_metaData",
              "maxReplicas",
              "pollingInterval",
              "minReplicas",
              "cooldownPeriod",
              "lagThreshold",
              "scaleType"
            ],
            "additionalProperties": false
          }
        ]
      }
    },
    "securitySchemes": {
      "jwt": {
        "type": "http",
        "scheme": "bearer",
        "bearerFormat": "JWT"
      }
    }
  },
  "info": {
    "title": "Contextual Agents Api",
    "description": " "
  },
  "servers": [
    {
      "url": "/api/v1"
    }
  ]
}
