Update a feature Stay organized with collections Save and categorize content based on your preferences.
Within a feature group, you can update a feature to associate it with a specific columnin the BigQuery data source that's associated with the feature group.
While creating or updating a feature, you have the option to add user-definedmetadata in the form of labels to the feature. For more information about howto update user-defined labels for a feature, seeUpdate labels for a feature.
Before you begin
Authenticate toVertex AI, unless you've done so already.
To use the REST API samples on this page in a local development environment, you use the credentials you provide to the gcloud CLI.
Install the Google Cloud CLI. After installation,initialize the Google Cloud CLI by running the following command:
gcloudinit
If you're using an external identity provider (IdP), you must first sign in to the gcloud CLI with your federated identity.
For more information, seeAuthenticate for using REST in the Google Cloud authentication documentation.
Update a feature
Use the following sample to update a feature within a feature group.
REST
To update aFeatureresource, send aPATCH request by using thefeatures.patchmethod.
Before using any of the request data, make the following replacements:
- LOCATION_ID: Region where the feature group containing the feature is located, such as
us-central1. - PROJECT_ID: Your project ID.
- FEATURE_GROUP_NAME: The name of the feature group containing the feature.
- FEATURE_NAME: The name of the feature you want to update.
- VERSION_COLUMN_NAME: The column from the BigQuery source table or view that you want to associate while updating the feature.
HTTP method and URL:
PATCH https://LOCATION_ID-aiplatform.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION_ID/featureGroups/FEATURE_GROUP_NAME/features?feature_id=FEATURE_NAME
Request JSON body:
{ "version_column_name": "VERSION_COLUMN_NAME"}To send your request, choose one of these options:
curl
Note: The following command assumes that you have logged in to thegcloud CLI with your user account by runninggcloud init orgcloud auth login , or by usingCloud Shell, which automatically logs you into thegcloud CLI . You can check the currently active account by runninggcloud auth list. Save the request body in a file namedrequest.json, and execute the following command:
curl -X PATCH \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
-H "Content-Type: application/json; charset=utf-8" \
-d @request.json \
"https://LOCATION_ID-aiplatform.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION_ID/featureGroups/FEATURE_GROUP_NAME/features?feature_id=FEATURE_NAME"
PowerShell
Note: The following command assumes that you have logged in to thegcloud CLI with your user account by runninggcloud init orgcloud auth login . You can check the currently active account by runninggcloud auth list. Save the request body in a file namedrequest.json, and execute the following command:
$cred = gcloud auth print-access-token
$headers = @{ "Authorization" = "Bearer $cred" }
Invoke-WebRequest `
-Method PATCH `
-Headers $headers `
-ContentType: "application/json; charset=utf-8" `
-InFile request.json `
-Uri "https://LOCATION_ID-aiplatform.googleapis.com/v1beta1/projects/PROJECT_ID/locations/LOCATION_ID/featureGroups/FEATURE_GROUP_NAME/features?feature_id=FEATURE_NAME" | Select-Object -Expand Content
You should receive a JSON response similar to the following:
{ "name": "projects/PROJECT_NUMBER/locations/LOCATION_ID/featureGroups/FEATURE_GROUP_NAME/features/FEATURE_NAME/operations/OPERATION_ID", "metadata": { "@type": "type.googleapis.com/google.cloud.aiplatform.v1beta1.UpdateFeatureOperationMetadata", "genericMetadata": { "createTime": "2023-09-18T02:36:22.870679Z", "updateTime": "2023-09-18T02:36:22.870679Z" } }, "done": true, "response": { "@type": "type.googleapis.com/google.cloud.aiplatform.v1beta1.Feature", "name": "projects/PROJECT_NUMBER/locations/LOCATION_ID/featureGroups/FEATURE_GROUP_NAME/features/FEATURE_NAME" }}What's next
Learn how tocreate a feature.
Learn how todelete a feature view.
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2026-02-18 UTC.