Configure and set up Metafield

Configure and set up Metafield in Dev Center

You need to define the Metafield Definitions In Developer Portal first.

  1. Go to Developer Portal > My Apps > Manage > Metafields, click "Edit" to configure Metafields Definition for the desired resource type.
  1. Click "Create"
  1. Fill in the following fields:
    1. Namespace: It defaults set as your app id and you do not need to edit it.
    2. Name: Enter a name for this Metafield to help you identify it in the Developer Portal.
    3. Key: This is the second part of the Metafield, representing the specific attribute. For example, "color."
      The combination of Namespace + Key forms the complete Metafield, such as "product.color."
    4. Description: Provide a brief description of this Metafield. This description will appear in the corresponding Metafield settings field in the Developer Portal. You can include details about what values should be entered for this Metafield.
    5. Content Type: Choose the type of content this Metafield will store in the admin panel, such as text, JSON, URL, number, or Boolean. For instance, if you are defining a Metafield related to "weight," the content type can be set to "number."

After creating the Metafield definition, you could create Metafield value for that resource by Open API


Configure Metafields Webhook

As a developers, your App may also want to monitor the changes of metafields definition or value if merchants make some changes on EC admin. Both merchant side & app metafields can register corresponding webhook to listen to the event. Please refer to the following link