---
updatedAt: 2026-05-29T17:03:57.000Z
agentTools:
  projectIndex: https://api-docs.render.com/llms.txt
---

# Update service

Update the service with the provided ID.

400 with `code: build_source_region_mismatch` if `buildSourceId` names a git-backed
Build Source in a different region than the service.


Update service allows you to update the configuration details of service, such as start commands and branches.

Changes will **not** be deployed automatically. Instead you must call the deploy API to have changes pushed out to your service, irrespective of the `autoDeploy` option set on the service.

# OpenAPI definition

```json
{
  "openapi": "3.0.2",
  "info": {
    "title": "Render Public API",
    "description": "Manage everything about your Render services",
    "version": "1.0.0",
    "contact": {
      "name": "Render API",
      "url": "https://community.render.com",
      "email": "support@render.com"
    }
  },
  "x-readme": {
    "metrics-enabled": false
  },
  "servers": [
    {
      "url": "https://api.render.com/v1"
    }
  ],
  "security": [
    {
      "BearerAuth": []
    }
  ],
  "tags": [
    {
      "name": "Services",
      "description": "[Services](https://render.com/docs/service-types) allow you to manage your web services, private services, background workers, cron jobs, and static sites.\n"
    }
  ],
  "paths": {
    "/disks/{diskId}": {
      "parameters": [
        {
          "name": "diskId",
          "in": "path",
          "required": true,
          "description": "The ID of the disk",
          "schema": {
            "type": "string",
            "pattern": "^dsk-[0-9a-z]{20}$",
            "example": "dsk-cph1rs3idesc73a2b2mg"
          }
        }
      ]
    },
    "/services/{serviceId}": {
      "parameters": [
        {
          "$ref": "#/components/parameters/serviceIdParam"
        }
      ],
      "patch": {
        "summary": "Update service",
        "description": "Update the service with the provided ID.\n\n400 with `code: build_source_region_mismatch` if `buildSourceId` names a git-backed\nBuild Source in a different region than the service.\n",
        "operationId": "update-service",
        "tags": [
          "Services"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/servicePATCH"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/service"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/400BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/401Unauthorized"
          },
          "402": {
            "$ref": "#/components/responses/402PaymentRequired"
          },
          "403": {
            "$ref": "#/components/responses/403Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/404NotFound"
          },
          "406": {
            "$ref": "#/components/responses/406NotAcceptable"
          },
          "409": {
            "$ref": "#/components/responses/409Conflict"
          },
          "410": {
            "$ref": "#/components/responses/410Gone"
          },
          "429": {
            "$ref": "#/components/responses/429RateLimit"
          },
          "500": {
            "$ref": "#/components/responses/500InternalServerError"
          },
          "503": {
            "$ref": "#/components/responses/503ServiceUnavailable"
          }
        }
      }
    },
    "/services/{serviceId}/autoscaling": {
      "parameters": [
        {
          "$ref": "#/components/parameters/serviceIdParam"
        }
      ],
      "put": {
        "summary": "Update autoscaling config",
        "description": "Update the [autoscaling](https://render.com/docs/scaling#autoscaling) config for the service with the provided ID.\n",
        "operationId": "autoscale-service",
        "tags": [
          "Services"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "type": "object",
                "required": [
                  "enabled",
                  "min",
                  "max",
                  "criteria"
                ],
                "properties": {
                  "enabled": {
                    "type": "boolean",
                    "default": false
                  },
                  "min": {
                    "type": "integer",
                    "description": "The minimum number of instances for the service"
                  },
                  "max": {
                    "type": "integer",
                    "description": "The maximum number of instances for the service"
                  },
                  "criteria": {
                    "type": "object",
                    "required": [
                      "cpu",
                      "memory"
                    ],
                    "properties": {
                      "cpu": {
                        "type": "object",
                        "required": [
                          "enabled",
                          "percentage"
                        ],
                        "properties": {
                          "enabled": {
                            "type": "boolean",
                            "default": false
                          },
                          "percentage": {
                            "type": "integer",
                            "description": "Determines when your service will be scaled. If the average resource utilization is significantly above/below the target, we will increase/decrease the number of instances.\n"
                          }
                        }
                      },
                      "memory": {
                        "$ref": "#/paths/~1services~1{serviceId}~1autoscaling/put/requestBody/content/application~1json/schema/properties/criteria/properties/cpu"
                      }
                    }
                  }
                }
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Autoscaling configuration updated",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/paths/~1services~1{serviceId}~1autoscaling/put/requestBody/content/application~1json/schema"
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/400BadRequest"
          },
          "401": {
            "$ref": "#/components/responses/401Unauthorized"
          },
          "403": {
            "$ref": "#/components/responses/403Forbidden"
          },
          "404": {
            "$ref": "#/components/responses/404NotFound"
          },
          "406": {
            "$ref": "#/components/responses/406NotAcceptable"
          },
          "410": {
            "$ref": "#/components/responses/410Gone"
          },
          "429": {
            "$ref": "#/components/responses/429RateLimit"
          },
          "500": {
            "$ref": "#/components/responses/500InternalServerError"
          },
          "503": {
            "$ref": "#/components/responses/503ServiceUnavailable"
          }
        }
      }
    },
    "/build-sources/{buildSourceId}": {
      "parameters": [
        {
          "name": "buildSourceId",
          "in": "path",
          "required": true,
          "schema": {
            "type": "string"
          }
        }
      ]
    }
  },
  "components": {
    "securitySchemes": {
      "BearerAuth": {
        "type": "http",
        "scheme": "bearer"
      }
    },
    "parameters": {
      "serviceIdParam": {
        "name": "serviceId",
        "in": "path",
        "required": true,
        "description": "The ID of the service",
        "schema": {
          "type": "string"
        }
      }
    },
    "schemas": {
      "service": {
        "type": "object",
        "required": [
          "id",
          "name",
          "ownerId",
          "type",
          "createdAt",
          "dashboardUrl",
          "updatedAt",
          "suspended",
          "suspenders",
          "autoDeploy",
          "notifyOnFail",
          "slug",
          "serviceDetails",
          "rootDir"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "buildSourceId": {
            "$ref": "#/paths/~1build-sources~1{buildSourceId}/parameters/0/schema",
            "description": "The ID of the Build Source the service builds and deploys from, if any. A git-backed Build Source must be in the same region as the service."
          },
          "autoDeploy": {
            "$ref": "#/components/schemas/autoDeploy"
          },
          "autoDeployTrigger": {
            "$ref": "#/components/schemas/servicePOST/properties/autoDeployTrigger"
          },
          "branch": {
            "type": "string"
          },
          "buildFilter": {
            "$ref": "#/components/schemas/buildFilter"
          },
          "createdAt": {
            "type": "string",
            "format": "date-time"
          },
          "dashboardUrl": {
            "type": "string",
            "description": "The URL to view the service in the Render Dashboard"
          },
          "environmentId": {
            "type": "string"
          },
          "imagePath": {
            "type": "string"
          },
          "name": {
            "type": "string"
          },
          "notifyOnFail": {
            "$ref": "#/components/schemas/notifySetting"
          },
          "ownerId": {
            "type": "string"
          },
          "registryCredential": {
            "$ref": "#/components/schemas/registryCredentialSummary"
          },
          "repo": {
            "type": "string",
            "example": "https://github.com/render-examples/flask-hello-world"
          },
          "rootDir": {
            "type": "string"
          },
          "slug": {
            "type": "string"
          },
          "suspended": {
            "type": "string",
            "title": "serviceSuspendedState",
            "enum": [
              "suspended",
              "not_suspended"
            ]
          },
          "suspenders": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/suspenderType"
            }
          },
          "type": {
            "$ref": "#/components/schemas/serviceType"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time"
          },
          "serviceDetails": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/staticSiteDetails"
              },
              {
                "$ref": "#/components/schemas/webServiceDetails"
              },
              {
                "$ref": "#/components/schemas/privateServiceDetails"
              },
              {
                "$ref": "#/components/schemas/backgroundWorkerDetails"
              },
              {
                "$ref": "#/components/schemas/cronJobDetails"
              }
            ]
          }
        }
      },
      "autoDeploy": {
        "type": "string",
        "enum": [
          "yes",
          "no"
        ],
        "default": "yes",
        "deprecated": true,
        "description": "Deprecated: use `autoDeployTrigger` instead. You can't set both `autoDeploy` and `autoDeployTrigger` in the same request.\n\n- `yes` is equivalent to `autoDeployTrigger: commit`.\n- `no` is equivalent to `autoDeployTrigger: off`.\n"
      },
      "buildFilter": {
        "type": "object",
        "required": [
          "paths",
          "ignoredPaths"
        ],
        "properties": {
          "paths": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "ignoredPaths": {
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        }
      },
      "registryCredentialSummary": {
        "type": "object",
        "required": [
          "id",
          "name"
        ],
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        }
      },
      "registryCredentialRegistry": {
        "type": "string",
        "enum": [
          "GITHUB",
          "GITLAB",
          "DOCKER",
          "GOOGLE_ARTIFACT",
          "AWS_ECR"
        ],
        "description": "The registry to use this credential with"
      },
      "registryCredential": {
        "type": "object",
        "required": [
          "id",
          "name",
          "username",
          "registry",
          "updatedAt"
        ],
        "properties": {
          "id": {
            "type": "string",
            "description": "Unique identifier for this credential"
          },
          "name": {
            "type": "string",
            "description": "Descriptive name for this credential"
          },
          "registry": {
            "$ref": "#/components/schemas/registryCredentialRegistry"
          },
          "username": {
            "type": "string",
            "description": "The username associated with the credential"
          },
          "updatedAt": {
            "type": "string",
            "format": "date-time",
            "description": "Last updated time for the credential"
          }
        }
      },
      "image": {
        "type": "object",
        "required": [
          "imagePath",
          "ownerId"
        ],
        "properties": {
          "ownerId": {
            "type": "string",
            "description": "The ID of the owner for this image. This should match the owner of the service as well as the owner of any specified registry credential."
          },
          "registryCredentialId": {
            "type": "string",
            "description": "Optional reference to the registry credential passed to the image repository to retrieve this image."
          },
          "imagePath": {
            "type": "string",
            "description": "Path to the image used for this server (e.g docker.io/library/nginx:latest)."
          }
        }
      },
      "dockerDetails": {
        "type": "object",
        "required": [
          "dockerCommand",
          "dockerContext",
          "dockerfilePath"
        ],
        "properties": {
          "dockerCommand": {
            "type": "string"
          },
          "dockerContext": {
            "type": "string"
          },
          "dockerfilePath": {
            "type": "string"
          },
          "preDeployCommand": {
            "type": "string"
          },
          "registryCredential": {
            "$ref": "#/components/schemas/registryCredential"
          }
        }
      },
      "nativeEnvironmentDetails": {
        "type": "object",
        "required": [
          "buildCommand",
          "startCommand"
        ],
        "properties": {
          "buildCommand": {
            "type": "string"
          },
          "startCommand": {
            "type": "string"
          },
          "preDeployCommand": {
            "type": "string"
          }
        }
      },
      "staticSiteDetails": {
        "type": "object",
        "required": [
          "buildCommand",
          "publishPath",
          "url",
          "buildPlan"
        ],
        "properties": {
          "buildCommand": {
            "type": "string"
          },
          "ipAllowList": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/cidrBlockAndDescription"
            }
          },
          "parentServer": {
            "$ref": "#/components/schemas/resource"
          },
          "publishPath": {
            "type": "string"
          },
          "pullRequestPreviewsEnabled": {
            "$ref": "#/components/schemas/pullRequestPreviewsEnabled"
          },
          "previews": {
            "$ref": "#/components/schemas/previews"
          },
          "url": {
            "type": "string"
          },
          "buildPlan": {
            "$ref": "#/components/schemas/buildPlan"
          },
          "renderSubdomainPolicy": {
            "$ref": "#/components/schemas/renderSubdomainPolicy"
          }
        }
      },
      "maintenanceMode": {
        "type": "object",
        "required": [
          "enabled",
          "uri"
        ],
        "properties": {
          "enabled": {
            "type": "boolean"
          },
          "uri": {
            "type": "string",
            "description": "The page to be served when [maintenance mode](https://render.com/docs/maintenance-mode) is enabled. When empty, the default maintenance mode page is served."
          }
        }
      },
      "maxShutdownDelaySeconds": {
        "type": "integer",
        "description": "The maximum amount of time (in seconds) that Render waits for your application process to exit gracefully after sending it a SIGTERM signal.",
        "minimum": 1,
        "maximum": 300,
        "default": 30
      },
      "webServiceDetails": {
        "type": "object",
        "required": [
          "env",
          "runtime",
          "envSpecificDetails",
          "plan",
          "region",
          "numInstances",
          "buildPlan",
          "healthCheckPath",
          "openPorts",
          "url"
        ],
        "properties": {
          "autoscaling": {
            "$ref": "#/paths/~1services~1{serviceId}~1autoscaling/put/requestBody/content/application~1json/schema"
          },
          "cache": {
            "$ref": "#/components/schemas/cache"
          },
          "disk": {
            "type": "object",
            "required": [
              "id",
              "name",
              "sizeGB",
              "mountPath"
            ],
            "properties": {
              "id": {
                "$ref": "#/paths/~1disks~1{diskId}/parameters/0/schema"
              },
              "name": {
                "type": "string"
              },
              "sizeGB": {
                "type": "integer"
              },
              "mountPath": {
                "type": "string"
              }
            }
          },
          "env": {
            "$ref": "#/components/schemas/serviceEnv"
          },
          "envSpecificDetails": {
            "$ref": "#/components/schemas/envSpecificDetails"
          },
          "healthCheckPath": {
            "type": "string"
          },
          "ipAllowList": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/cidrBlockAndDescription"
            }
          },
          "maintenanceMode": {
            "$ref": "#/components/schemas/maintenanceMode"
          },
          "numInstances": {
            "type": "integer",
            "description": "For a *manually* scaled service, this is the number of instances the service is scaled to. DOES NOT indicate the number of running instances for an *autoscaled* service."
          },
          "openPorts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/serverPort"
            }
          },
          "parentServer": {
            "$ref": "#/components/schemas/resource"
          },
          "plan": {
            "$ref": "#/components/schemas/plan"
          },
          "pullRequestPreviewsEnabled": {
            "$ref": "#/components/schemas/pullRequestPreviewsEnabled"
          },
          "previews": {
            "$ref": "#/components/schemas/previews"
          },
          "region": {
            "$ref": "#/components/schemas/region"
          },
          "runtime": {
            "$ref": "#/components/schemas/serviceRuntime"
          },
          "sshAddress": {
            "$ref": "#/components/schemas/sshAddress"
          },
          "url": {
            "type": "string"
          },
          "buildPlan": {
            "$ref": "#/components/schemas/buildPlan"
          },
          "maxShutdownDelaySeconds": {
            "$ref": "#/components/schemas/maxShutdownDelaySeconds"
          },
          "renderSubdomainPolicy": {
            "$ref": "#/components/schemas/renderSubdomainPolicy"
          }
        }
      },
      "envSpecificDetails": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/dockerDetails"
          },
          {
            "$ref": "#/components/schemas/nativeEnvironmentDetails"
          }
        ]
      },
      "envSpecificDetailsPATCH": {
        "oneOf": [
          {
            "$ref": "#/components/schemas/dockerDetailsPATCH"
          },
          {
            "$ref": "#/components/schemas/nativeEnvironmentDetailsPATCH"
          }
        ]
      },
      "resource": {
        "required": [
          "id",
          "name"
        ],
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "name": {
            "type": "string"
          }
        }
      },
      "privateServiceDetails": {
        "type": "object",
        "required": [
          "env",
          "runtime",
          "envSpecificDetails",
          "plan",
          "region",
          "numInstances",
          "buildPlan",
          "openPorts",
          "url"
        ],
        "properties": {
          "autoscaling": {
            "$ref": "#/paths/~1services~1{serviceId}~1autoscaling/put/requestBody/content/application~1json/schema"
          },
          "disk": {
            "$ref": "#/components/schemas/webServiceDetails/properties/disk"
          },
          "env": {
            "$ref": "#/components/schemas/serviceEnv"
          },
          "envSpecificDetails": {
            "$ref": "#/components/schemas/envSpecificDetails"
          },
          "numInstances": {
            "type": "integer",
            "description": "For a *manually* scaled service, this is the number of instances the service is scaled to. DOES NOT indicate the number of running instances for an *autoscaled* service."
          },
          "openPorts": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/serverPort"
            }
          },
          "parentServer": {
            "$ref": "#/components/schemas/resource"
          },
          "plan": {
            "$ref": "#/components/schemas/plan"
          },
          "pullRequestPreviewsEnabled": {
            "$ref": "#/components/schemas/pullRequestPreviewsEnabled"
          },
          "previews": {
            "$ref": "#/components/schemas/previews"
          },
          "region": {
            "$ref": "#/components/schemas/region"
          },
          "runtime": {
            "$ref": "#/components/schemas/serviceRuntime"
          },
          "sshAddress": {
            "$ref": "#/components/schemas/sshAddress"
          },
          "url": {
            "type": "string"
          },
          "buildPlan": {
            "$ref": "#/components/schemas/buildPlan"
          },
          "maxShutdownDelaySeconds": {
            "$ref": "#/components/schemas/maxShutdownDelaySeconds"
          }
        }
      },
      "cache": {
        "type": "object",
        "required": [
          "profile"
        ],
        "properties": {
          "profile": {
            "type": "string",
            "enum": [
              "no-cache",
              "origin-controlled",
              "origin-controlled-all"
            ],
            "default": "no-cache"
          }
        }
      },
      "backgroundWorkerDetails": {
        "type": "object",
        "required": [
          "env",
          "runtime",
          "envSpecificDetails",
          "plan",
          "region",
          "numInstances",
          "buildPlan"
        ],
        "properties": {
          "autoscaling": {
            "$ref": "#/paths/~1services~1{serviceId}~1autoscaling/put/requestBody/content/application~1json/schema"
          },
          "disk": {
            "$ref": "#/components/schemas/webServiceDetails/properties/disk"
          },
          "env": {
            "$ref": "#/components/schemas/serviceEnv"
          },
          "envSpecificDetails": {
            "$ref": "#/components/schemas/envSpecificDetails"
          },
          "numInstances": {
            "type": "integer",
            "description": "For a *manually* scaled service, this is the number of instances the service is scaled to. DOES NOT indicate the number of running instances for an *autoscaled* service."
          },
          "parentServer": {
            "$ref": "#/components/schemas/resource"
          },
          "plan": {
            "$ref": "#/components/schemas/plan"
          },
          "pullRequestPreviewsEnabled": {
            "$ref": "#/components/schemas/pullRequestPreviewsEnabled"
          },
          "previews": {
            "$ref": "#/components/schemas/previews"
          },
          "region": {
            "$ref": "#/components/schemas/region"
          },
          "runtime": {
            "$ref": "#/components/schemas/serviceRuntime"
          },
          "sshAddress": {
            "$ref": "#/components/schemas/sshAddress"
          },
          "buildPlan": {
            "$ref": "#/components/schemas/buildPlan"
          },
          "maxShutdownDelaySeconds": {
            "$ref": "#/components/schemas/maxShutdownDelaySeconds"
          }
        }
      },
      "cronJobDetails": {
        "required": [
          "env",
          "runtime",
          "envSpecificDetails",
          "plan",
          "region",
          "schedule",
          "buildPlan"
        ],
        "type": "object",
        "properties": {
          "env": {
            "$ref": "#/components/schemas/serviceEnv"
          },
          "envSpecificDetails": {
            "$ref": "#/components/schemas/envSpecificDetails"
          },
          "lastSuccessfulRunAt": {
            "type": "string",
            "format": "date-time"
          },
          "plan": {
            "$ref": "#/components/schemas/plan"
          },
          "region": {
            "$ref": "#/components/schemas/region"
          },
          "runtime": {
            "$ref": "#/components/schemas/serviceRuntime"
          },
          "schedule": {
            "type": "string"
          },
          "buildPlan": {
            "$ref": "#/components/schemas/buildPlan"
          }
        }
      },
      "servicePOST": {
        "type": "object",
        "required": [
          "type",
          "name",
          "ownerId"
        ],
        "properties": {
          "type": {
            "$ref": "#/components/schemas/serviceType"
          },
          "name": {
            "type": "string",
            "description": "The service's name. Must be unique within the workspace."
          },
          "ownerId": {
            "type": "string",
            "description": "The ID of the workspace the service belongs to. Obtain your workspace's ID from its Settings page in the Render Dashboard."
          },
          "repo": {
            "type": "string",
            "example": "https://github.com/render-examples/flask-hello-world",
            "description": "The service's repository URL. Do not specify a branch in this string (use the `branch` parameter instead)."
          },
          "autoDeploy": {
            "$ref": "#/components/schemas/autoDeploy"
          },
          "autoDeployTrigger": {
            "type": "string",
            "enum": [
              "commit",
              "off",
              "checksPass"
            ],
            "description": "Controls autodeploy behavior.\n\n- `commit`: Deploy each time a commit is pushed to the service's linked branch.\n- `checksPass`: Deploy each time a commit is pushed to the linked branch, but only after the commit's CI checks pass.\n- `off`: Disable autodeploys.\n"
          },
          "branch": {
            "type": "string",
            "description": "The repo branch to pull, build, and deploy. If omitted, uses the repository's default branch."
          },
          "image": {
            "$ref": "#/components/schemas/image"
          },
          "buildFilter": {
            "$ref": "#/components/schemas/buildFilter"
          },
          "rootDir": {
            "type": "string"
          },
          "envVars": {
            "$ref": "#/paths/~1services~1{serviceId}~1env-vars/put/requestBody/content/application~1json/schema"
          },
          "secretFiles": {
            "type": "array",
            "items": {
              "$ref": "#/paths/~1services~1{serviceId}~1secret-files/put/requestBody/content/application~1json/schema/items"
            }
          },
          "environmentId": {
            "type": "string",
            "description": "The ID of the environment the service belongs to, if any. Obtain an environment's ID from its Settings page in the Render Dashboard."
          },
          "serviceDetails": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/staticSiteDetailsPOST"
              },
              {
                "$ref": "#/components/schemas/webServiceDetailsPOST"
              },
              {
                "$ref": "#/components/schemas/privateServiceDetailsPOST"
              },
              {
                "$ref": "#/components/schemas/backgroundWorkerDetailsPOST"
              },
              {
                "$ref": "#/components/schemas/cronJobDetailsPOST"
              }
            ]
          }
        }
      },
      "servicePATCH": {
        "type": "object",
        "properties": {
          "buildSourceId": {
            "$ref": "#/paths/~1build-sources~1{buildSourceId}/parameters/0/schema",
            "description": "The ID of the Build Source to link this service to. Cannot be combined with build-configuration changes or other `serviceDetails` fields, except `startCommand`. Linking to a Build Source with a native runtime requires a start command, either in this request or already set on the service. Linking to a Build Source with a Docker or image runtime rejects a start command. A git-backed Build Source must be in the same region as the service; otherwise the request is rejected with 400 and `code: build_source_region_mismatch`."
          },
          "autoDeploy": {
            "$ref": "#/components/schemas/autoDeploy"
          },
          "autoDeployTrigger": {
            "$ref": "#/components/schemas/servicePOST/properties/autoDeployTrigger"
          },
          "repo": {
            "type": "string"
          },
          "branch": {
            "type": "string"
          },
          "image": {
            "$ref": "#/components/schemas/image"
          },
          "name": {
            "type": "string"
          },
          "buildFilter": {
            "$ref": "#/components/schemas/buildFilter"
          },
          "rootDir": {
            "type": "string"
          },
          "serviceDetails": {
            "oneOf": [
              {
                "$ref": "#/components/schemas/staticSiteDetailsPATCH"
              },
              {
                "$ref": "#/components/schemas/webServiceDetailsPATCH"
              },
              {
                "$ref": "#/components/schemas/privateServiceDetailsPATCH"
              },
              {
                "$ref": "#/components/schemas/backgroundWorkerDetailsPATCH"
              },
              {
                "$ref": "#/components/schemas/cronJobDetailsPATCH"
              }
            ]
          }
        }
      },
      "dockerDetailsPATCH": {
        "type": "object",
        "properties": {
          "dockerCommand": {
            "type": "string"
          },
          "dockerContext": {
            "type": "string"
          },
          "dockerfilePath": {
            "type": "string"
          },
          "registryCredentialId": {
            "type": "string",
            "description": "Optional reference to the registry credential for this build. Omit the field to leave the stored credential unchanged; send an empty string to clear it."
          }
        }
      },
      "nativeEnvironmentDetailsPATCH": {
        "type": "object",
        "properties": {
          "buildCommand": {
            "type": "string"
          },
          "startCommand": {
            "type": "string"
          }
        }
      },
      "staticSiteDetailsPATCH": {
        "type": "object",
        "properties": {
          "buildCommand": {
            "type": "string"
          },
          "publishPath": {
            "type": "string"
          },
          "pullRequestPreviewsEnabled": {
            "$ref": "#/components/schemas/pullRequestPreviewsEnabled"
          },
          "previews": {
            "$ref": "#/components/schemas/previews"
          },
          "renderSubdomainPolicy": {
            "$ref": "#/components/schemas/renderSubdomainPolicy"
          },
          "ipAllowList": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/cidrBlockAndDescription"
            }
          }
        }
      },
      "webServiceDetailsPATCH": {
        "type": "object",
        "properties": {
          "envSpecificDetails": {
            "$ref": "#/components/schemas/envSpecificDetailsPATCH"
          },
          "healthCheckPath": {
            "type": "string"
          },
          "maintenanceMode": {
            "$ref": "#/components/schemas/maintenanceMode"
          },
          "plan": {
            "$ref": "#/components/schemas/plan"
          },
          "preDeployCommand": {
            "type": "string"
          },
          "pullRequestPreviewsEnabled": {
            "$ref": "#/components/schemas/pullRequestPreviewsEnabled"
          },
          "previews": {
            "$ref": "#/components/schemas/previews"
          },
          "runtime": {
            "$ref": "#/components/schemas/serviceRuntime"
          },
          "maxShutdownDelaySeconds": {
            "$ref": "#/components/schemas/maxShutdownDelaySeconds"
          },
          "renderSubdomainPolicy": {
            "$ref": "#/components/schemas/renderSubdomainPolicy"
          },
          "ipAllowList": {
            "type": "array",
            "items": {
              "$ref": "#/components/schemas/cidrBlockAndDescription"
            }
          },
          "cache": {
            "$ref": "#/components/schemas/cache"
          }
        }
      },
      "privateServiceDetailsPATCH": {
        "type": "object",
        "properties": {
          "envSpecificDetails": {
            "$ref": "#/components/schemas/envSpecificDetailsPATCH"
          },
          "plan": {
            "$ref": "#/components/schemas/paidPlan"
          },
          "preDeployCommand": {
            "type": "string"
          },
          "pullRequestPreviewsEnabled": {
            "$ref": "#/components/schemas/pullRequestPreviewsEnabled"
          },
          "previews": {
            "$ref": "#/components/schemas/previews"
          },
          "runtime": {
            "$ref": "#/components/schemas/serviceRuntime"
          },
          "maxShutdownDelaySeconds": {
            "$ref": "#/components/schemas/maxShutdownDelaySeconds"
          }
        }
      },
      "backgroundWorkerDetailsPATCH": {
        "type": "object",
        "properties": {
          "envSpecificDetails": {
            "$ref": "#/components/schemas/envSpecificDetailsPATCH"
          },
          "plan": {
            "$ref": "#/components/schemas/paidPlan"
          },
          "preDeployCommand": {
            "type": "string"
          },
          "pullRequestPreviewsEnabled": {
            "$ref": "#/components/schemas/pullRequestPreviewsEnabled"
          },
          "previews": {
            "$ref": "#/components/schemas/previews"
          },
          "runtime": {
            "$ref": "#/components/schemas/serviceRuntime"
          },
          "maxShutdownDelaySeconds": {
            "$ref": "#/components/schemas/maxShutdownDelaySeconds"
          }
        }
      },
      "cronJobDetailsPATCH": {
        "type": "object",
        "properties": {
          "envSpecificDetails": {
            "$ref": "#/components/schemas/envSpecificDetailsPATCH"
          },
          "plan": {
            "$ref": "#/components/schemas/paidPlan"
          },
          "schedule": {
            "type": "string"
          },
          "runtime": {
            "$ref": "#/components/schemas/serviceRuntime"
          }
        }
      },
      "plan": {
        "type": "string",
        "enum": [
          "starter",
          "starter_plus",
          "standard",
          "standard_plus",
          "pro",
          "pro_plus",
          "pro_max",
          "pro_ultra",
          "free",
          "custom",
          "starter_legacy",
          "standard_legacy",
          "standard_plus_legacy",
          "pro_legacy",
          "pro_plus_legacy",
          "0.5c-512mb",
          "1c-2g",
          "2c-4g",
          "2c-8g",
          "2c-16g",
          "4c-8g",
          "4c-16g",
          "4c-32g",
          "8c-16g",
          "8c-32g",
          "8c-64g",
          "12c-24g",
          "12c-48g",
          "12c-96g"
        ],
        "example": "starter",
        "description": "The compute plan to use. Legacy variants (`*_legacy`) identify grandfathered plans no longer offered for new services. Note that base services on any paid compute plan can't create preview instances with the `free` plan."
      },
      "serviceType": {
        "type": "string",
        "enum": [
          "static_site",
          "web_service",
          "private_service",
          "background_worker",
          "cron_job"
        ]
      },
      "serviceRuntime": {
        "type": "string",
        "enum": [
          "docker",
          "elixir",
          "go",
          "node",
          "python",
          "ruby",
          "rust",
          "image"
        ],
        "description": "Runtime"
      },
      "serviceEnv": {
        "type": "string",
        "enum": [
          "docker",
          "elixir",
          "go",
          "node",
          "python",
          "ruby",
          "rust",
          "image"
        ],
        "deprecated": true,
        "description": "This field has been deprecated, runtime should be used in its place."
      },
      "sshAddress": {
        "type": "string",
        "description": "The SSH address for the service. Only present for services that have SSH enabled."
      },
      "region": {
        "type": "string",
        "enum": [
          "frankfurt",
          "oregon",
          "ohio",
          "singapore",
          "virginia"
        ],
        "default": "oregon",
        "description": "Defaults to \"oregon\""
      },
      "notifySetting": {
        "type": "string",
        "enum": [
          "default",
          "notify",
          "ignore"
        ]
      },
      "suspenderType": {
        "type": "string",
        "enum": [
          "admin",
          "billing",
          "user",
          "parent_service",
          "stuck_crashlooping",
          "hipaa_enablement",
          "unknown"
        ]
      },
      "serverPort": {
        "type": "object",
        "required": [
          "port",
          "protocol"
        ],
        "properties": {
          "port": {
            "type": "integer",
            "example": 10000
          },
          "protocol": {
            "type": "string",
            "enum": [
              "TCP",
              "UDP"
            ]
          }
        }
      },
      "error": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "message": {
            "type": "string"
          },
          "code": {
            "type": "string",
            "description": "A stable, machine-readable identifier present on specific errors that clients can handle specially. Each endpoint documents the codes it can return. The errorCode schema lists the full vocabulary of codes."
          }
        }
      },
      "pullRequestPreviewsEnabled": {
        "type": "string",
        "enum": [
          "yes",
          "no"
        ],
        "default": "no",
        "deprecated": true,
        "description": "This field has been deprecated. previews.generation should be used in its place."
      },
      "previews": {
        "type": "object",
        "properties": {
          "generation": {
            "type": "string",
            "enum": [
              "off",
              "manual",
              "automatic"
            ],
            "default": "off",
            "description": "Defaults to \"off\""
          }
        }
      },
      "buildPlan": {
        "type": "string",
        "enum": [
          "starter",
          "performance"
        ],
        "default": "starter"
      },
      "renderSubdomainPolicy": {
        "type": "string",
        "enum": [
          "enabled",
          "disabled"
        ],
        "description": "Controls whether render.com subdomains are available for the service"
      },
      "cidrBlockAndDescription": {
        "type": "object",
        "required": [
          "cidrBlock",
          "description"
        ],
        "properties": {
          "cidrBlock": {
            "type": "string"
          },
          "description": {
            "description": "User-provided description of the CIDR block",
            "type": "string"
          }
        }
      },
      "paidPlan": {
        "type": "string",
        "enum": [
          "starter",
          "standard",
          "pro",
          "pro_plus",
          "pro_max",
          "pro_ultra",
          "0.5c-512mb",
          "1c-2g",
          "2c-4g",
          "2c-8g",
          "2c-16g",
          "4c-8g",
          "4c-16g",
          "4c-32g",
          "8c-16g",
          "8c-32g",
          "8c-64g",
          "12c-24g",
          "12c-48g",
          "12c-96g"
        ],
        "default": "0.5c-512mb",
        "description": "Defaults to `0.5c-512mb` when creating a new service."
      }
    },
    "responses": {
      "400BadRequest": {
        "description": "The request could not be understood by the server.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      },
      "401Unauthorized": {
        "description": "Authorization information is missing or invalid.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      },
      "402PaymentRequired": {
        "description": "You must enter payment information to perform this request.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      },
      "403Forbidden": {
        "description": "You do not have permissions for the requested resource. If a scoped API token does not satisfy the endpoint's minimum scope requirements, the response has code insufficient_token_scope and its message lists all minimum required scopes. Broader scopes that include their permissions also satisfy the requirements. Passing this check does not guarantee access to the requested resource or to conditional operations.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      },
      "404NotFound": {
        "description": "Unable to find the requested resource.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      },
      "406NotAcceptable": {
        "description": "Unable to generate preferred media types as specified by Accept request header.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      },
      "409Conflict": {
        "description": "The current state of the resource conflicts with this request.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      },
      "410Gone": {
        "description": "The requested resource is no longer available.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      },
      "429RateLimit": {
        "description": "Rate limit has been surpassed.\n\nRate-limited endpoints also return `RateLimit-Limit`, `RateLimit-Remaining`, and `RateLimit-Reset` on successful responses so clients can track their remaining quota.\n",
        "headers": {
          "Retry-After": {
            "description": "Seconds to wait before retrying the request.",
            "schema": {
              "type": "integer",
              "example": 30
            }
          },
          "RateLimit-Limit": {
            "description": "Maximum number of requests allowed in the current window.",
            "schema": {
              "type": "integer",
              "example": 100
            }
          },
          "RateLimit-Remaining": {
            "description": "Number of requests remaining in the current window. `0` when the request rate limit is exceeded; may be nonzero for capacity limits or temporary conflicts.",
            "schema": {
              "type": "integer",
              "example": 0
            }
          },
          "RateLimit-Reset": {
            "description": "Seconds until the current rate limit window resets.",
            "schema": {
              "type": "integer",
              "example": 30
            }
          }
        },
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            },
            "example": {
              "message": "rate limit exceeded"
            }
          }
        }
      },
      "500InternalServerError": {
        "description": "An unexpected server error has occurred.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      },
      "503ServiceUnavailable": {
        "description": "Server currently unavailable.",
        "content": {
          "application/json": {
            "schema": {
              "$ref": "#/components/schemas/error"
            }
          }
        }
      }
    }
  }
}
```