Back to blog
Blog

Edit Object Metafields

Tony Spiro's avatar

Tony Spiro

August 23, 2019

cover image

You can now edit specific Metafields on existing Objects via the API. The following API method allows you to edit specific Metafields identified by key, without affecting other Metafields as well as add new Metafields. View in the docs.

The endpoint is:

PATCH https://api.cosmicjs.com/v1/:bucket_slug/edit-object-metafields

Body properties:

slug (String)
metafields (Array)


The Cosmic NPM module is also updated (3.2.19) to allow for this capability with the new method:

bucket.editObjectMetafields()

Further directions are available in the Metafields section in the REST API documentation.


Let me know if you have any questions. Join us on Slack and on Twitter.