Skip to content
Ona Docs

UpdateEnvironmentClass

runners.configurations.environment_classes.update(EnvironmentClassUpdateParams**kwargs) -> object
POST/gitpod.v1.RunnerConfigurationService/UpdateEnvironmentClass

Updates an environment class.

Use this method to:

  • Modify class settings
  • Update resource limits
  • Change availability

Examples

  • Update class:

    Changes class configuration.

    environmentClassId: "d2c94c27-3b76-4a42-b88c-95a85e392c68"
    displayName: "Updated Large Instance"
    description: "16 CPU, 32GB RAM"
    enabled: true
ParametersExpand Collapse
description: Optional[str]
maxLength200
minLength3
display_name: Optional[str]
maxLength127
minLength3
enabled: Optional[bool]
environment_class_id: Optional[str]
formatuuid
ReturnsExpand Collapse
object

UpdateEnvironmentClass

import os
from gitpod import Gitpod

client = Gitpod(
    bearer_token=os.environ.get("GITPOD_API_KEY"),  # This is the default and can be omitted
)
environment_class = client.runners.configurations.environment_classes.update(
    description="16 CPU, 32GB RAM",
    display_name="Updated Large Instance",
    enabled=True,
    environment_class_id="d2c94c27-3b76-4a42-b88c-95a85e392c68",
)
print(environment_class)
{}
Returns Examples
{}