Migrate metafields

In the 2021-07 API version release, the value_type field on the Metafield object was deprecated. As of the 2022-01 API version release, the value_type field has been removed from these APIs.

  • In the REST Admin API, the type property replaces the value_type property in the Metafield resource.
  • In the GraphQL Admin API, the type field replaces the valueType field in the Metafield object.

This guide describes how you can migrate your metafields from using value_type to type in the REST Admin API and GraphQL Admin API.