Metafields

Modified on Tue, 17 Oct, 2023 at 3:50 PM






If the metafield you are trying to update is not created in your store, then Stock Sync will create the metafield but Adding snippets into Shopify Theme Liquid needs to be done manually.


If the feed file doesn't have any column as metafield and wants to apply the metafield as the default value for all the products. You can use fixed value to set it. 


When it comes to metafields, several options are available such as metafield 1, 2, 3, and so on. Additionally, a few settings are provided. 

Let's take a closer look at the explanation of these settings below.


1. Metafield Namespace and Key

The dropdown will display the list of metafields available in the store. It also displays the Owner and Content Type respectively.
 


How to update Google Fields using Metafields with Stock Sync?

Please click here to know more. 




2. Metafield Owner

Based on your Shopify admin settings, this field has been prefilled.



3. Metafield Content Type

Based on your Shopify admin settings, this field has been prefilled.


Name

Description

Example value

Single line text

A single-line text field.

This item contains dairy products.

Multi-line text

A multi-line text field.

Ingredients:

Flour

Water

Milk

Eggs

Integer

A whole number in the range of +/-9,007,199,254,740,991.

10

Decimal

A number with decimal places in the range of +/-9999999999999.999999999.

10.4

Date

A date in ISO 8601 format without a presumed timezone. 

%Y-%m-%

Date and time

A date and time in ISO 8601 format without a presumed timezone.

2021-01-01T12:30:00

URL

A URL with one of the allowed schemes: httpshttpmailtosmstel.

https://www.shopify.com

JSON string

A JSON-formatted string.

Note: The json_string type is deprecated but still exists because it behaves differently than the new json type in Liquid.

[{ "k": "v1" }, { "k": "v2" }]

Boolean

A true or false value.

TRUE

Color

The hexadecimal code for a color.

#fff123

Weight

A value and a unit of weight. Valid unit values: ozlbgkg

{ "unit": "kg", "value": 2.5 }

Volume

A value and a unit of volume. Valid unit values: mlcllm3 (cubic meters), us_fl_ozus_ptus_qtus_galimp_fl_ozimp_ptimp_qtimp_gal.

{ "unit": "ml", "value": 20.0 }

Dimension

A value and a unit of length. Valid unit values: inftydmmcmm

{ "unit": "cm", "value": 25.0 }

Rating

A rating measured on a specified scale

-

Rich TextWe do not support this at the moment. 




How do i set the metafield content type true and false value ?

To know more about this can refer here.



To view the accurate format of metafield, please do open your feed file via notes or notepad so that can see it clearly. 

If open via excel, it could change some of the value formatting such as numbers and dates. 



For example, if you have a metafield like this:

Namespace
Key
Value
EstimatedTimeArrival
ETA
1 day
EstimatedTimeArrival
ETA
2 days



The Namespace is the Estimated Time of Arrival, the Key is ETA, and the Value will be attached to the Product of the Variant according to the metafield owner.

For the metafield type, you should choose the correct data type. The data type also must be the same in Stock Sync and Shopify. 

If not, it will get an error. Can refer here to know more.




4. Default value if cell is blank


Default value if the cell is blank. If the feed has a blank cell for a product, then the default value will be added to the metafield value instead. The default value can't be left blank.




To remove the metafield of blank value
If you need assistance to remove the metafield of blank values, you can reach out to us at support@stock-sync.com and we will help you enable it.






   

Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article