[Yandex Cloud documentation](../../index.md) > [Yandex Managed Service for Apache Spark™](../index.md) > [Step-by-step guides](index.md) > Environments > Updating a workspace

# Updating an environment

After creating an environment, you can update its general information: name, description, and labels. If you want to change the list of packages or your Apache Spark™ version, [create a new environment based on the existing one](environment-create.md#create-copy-env) and make the necessary changes.

{% list tabs group=instructions %}

- Management console {#console}

  1. In the [management console](https://console.yandex.cloud), select the folder.
  1. [Navigate](https://console.yandex.cloud/link/managed-spark) to **Managed Service for Apache Spark™**.
  1. In the left-hand panel, select ![image](../../_assets/console-icons/cubes-3.svg) **Environments**.
  1. Select the required environment from the list, navigate to it, and click **Edit** on the top panel.
  1. Under **General information**, update the environment name, description, and labels. 
  1. Click **Save changes**.

- gRPC API {#grpc-api}

    1. [Get an IAM token for API authentication](../api-ref/authentication.md) and put it into an environment variable:

       ```bash
       export IAM_TOKEN="<IAM_token>"
       ```

    1. Clone the [cloudapi](https://github.com/yandex-cloud/cloudapi) repository:
       
       ```bash
       cd ~/ && git clone --depth=1 https://github.com/yandex-cloud/cloudapi
       ```
       
       Below, we assume that the repository contents reside in the `~/cloudapi/` directory.

    1. Use the [EnvironmentService/Update](../environment/api-ref/grpc/Environment/update.md) call to update the environment:

       ```bash
       grpcurl \
         -format json \
         -import-path ~/cloudapi/ \
         -import-path ~/cloudapi/third_party/googleapis/ \
         -proto ~/cloudapi/yandex/cloud/spark/v1/environment/environment_service.proto \
         -rpc-header "Authorization: Bearer $IAM_TOKEN" \
         -d '{
                "environment_id": "<environment_ID>",
                "update_mask": {
                  "paths": [
                    "name",
                    "description"
                  ]
                },
                "name": "<new_environment_name>",
                "description": "<new_environment_description>"
            }' \
         spark.api.cloud.yandex.net:443 \
         yandex.cloud.spark.v1.environment.EnvironmentService.Update
       ```

       To get your environment ID, call the [EnvironmentService/List](../environment/api-ref/grpc/Environment/list.md) method.

       In `update_mask`, list the parameters to update. Provide new values in relevant fields.

    1. Check the [server response](../environment/api-ref/grpc/Environment/update.md#yandex.cloud.operation.Operation) to make sure your request was successful.

{% endlist %}