I'm looking fo add a List of Strings value to properties of an image collection in google earth similar to Copernicus CORINE Land Cover: https://developers.google.com/earth-engine/datasets/catalog/COPERNICUS_CORINE_V20_100m#image-properties
I tried this code:
var assetId = 'your-image-collection-id'
var lis = "one"
// Update the properties of the asset in Earth Engine.
var task =ee.data.setAssetProperties(assetId, {
'prova': lis})
It works but It doesn't accept list
then I tried this other code:
// ID dell'Image Collection
var collectionId = 'your-image-collection-id';
// Recupera l'Image Collection
var collection = ee.ImageCollection(collectionId);
// Crea un oggetto JSON che rappresenta le proprietà da inserire
var newProperties = { 'property_name_1': ['one' , 'two', 'three' , ] };
// Aggiorna le proprietà dell'Image Collection
var updatedCollection = collection.set(newProperties);
// Salva le proprietà aggiornate sull'Asset Earth Engine
var task = ee.data.updateAsset({ assetId: collectionId, properties: newProperties });
// Verifica lo stato della task
var status = task.status();
and this is the error:
Asset 'projects/earthengine-public/assets/[object Object]' does not exist or doesn't allow this operation
but the id is correct and the asset is mine.
Any suggestion is welcome