Solved

Access unit_price and unit_price_measurement via REST API

tipserstore
Tourist
4 0 4

Price Per Unit is an exclusive feature implemented for France and Germany.
https://help.shopify.com/en/manual/intro-to-shopify/initial-setup/sell-in-germany/price-per-unit

https://help.shopify.com/en/manual/intro-to-shopify/initial-setup/sell-in-france/price-per-unit

I went through guideless ^ and was able to define the unit price via the user interface. Now, I want to download these data via REST API. Is it accessible there? Precisely,  is a price per unit (unit_price and unit_price_measurement) exposed via REST API or GraphQL? I can't see it as a variant property.

Accepted Solution (1)

Josh
Shopify Staff
1134 84 233

This is an accepted solution.

Hey @tipserstore , 

 

At the moment this field is not accessible via the API. However, it is also very new, so that's not to say that it never will be available - but there isn't any timeline at the moment or concrete plans to do so. 

Josh | Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

View solution in original post

Replies 54 (54)

Josh
Shopify Staff
1134 84 233

This is an accepted solution.

Hey @tipserstore , 

 

At the moment this field is not accessible via the API. However, it is also very new, so that's not to say that it never will be available - but there isn't any timeline at the moment or concrete plans to do so. 

Josh | Shopify 
 - Was my reply helpful? Click Like to let me know! 
 - Was your question answered? Mark it as an Accepted Solution
 - To learn more visit the Shopify Help Center or the Shopify Blog

bauerundmetzger
Tourist
5 0 3
Hi from Germany,

is there any update on this field? We setup our new online shop and need to adjust the unit price for our wholesale clients. We need to run two shops in one: B2C and B2B. This is practically possible with Apps like Wholesale gorilla or Bold. But both aren’t able to change the unit prices, in our case /kg. But we need to show different prices for B2B clients. Is there any solution for us from shopify or via an third party app? Thanks for help!
Maris
Shopify Partner
319 5 71

Hello!

 

Is there any update on this - when would it be possible to read/write this `unit_price` and `unit_price_measurement` data via the Shopify REST API or GraphQL?

 

Thanks so much!

 

Maris

 

Matrixify (Excelify) | Bulk Import Export Update Migrate | https://matrixify.app
FabianPG
Tourist
6 0 18

Hi @tipserstore , do you have any update on making these fields available through the APIs ?

 

This is really crucial information for all stores in Europe (particularly Germany and France, where the feature has been thankfully rolled out on the user interface).

 

However, in order to safely maintain the data we need these fields to be accessible via API.

 

Also, it would be tremendously helpful if the values could be carried over to the Google Shopping App's unit price fields whenever there is a change in Shopify (either through the user interface or via the API). Is that something that is aimed to come anytime soon ?

 

Thank you & Best Regards

Fabian

HunkyBill
Shopify Expert
4845 60 547

Why would this feature be exclusive to France and Germany? Unit price has been in demand since DAY 1 of Shopify, in every part of the world? Curious about this. Never heard a peep about it finally being a thing. Anyone at Shopify ever produce a blog article on this and what it came from, how it works etc?

Custom Shopify Apps built just for you! hunkybill@gmail.com http://www.resistorsoftware.com
grimabe
Tourist
3 0 4

Hi @Josh , do you have any news regarding this topic?

Thanks

Benjamin

FabianPG
Tourist
6 0 18

Hi @Josh , also anxiously waiting for this to be added to the API accesible fields.

@all lets make some noise here to show that it's not only a select few who need this feature.

 

Thanks & Regards

Fabian

Deluxe
Shopify Partner
5 0 6

need it urgently!!

SewMuchCommerce
Shopify Expert
20 0 2

Not sure if it would help anyone but my app helps fabric stores sell in fractional increments. For example allowing a customer to purchase 1.75 yards or meters of fabric.

 

I have a few requests for kg or g but its not many, shoot me an email at James@SewMuchCommerce.com with your specific issues/needs and I'll see what I can do.

HunkyBill
Shopify Expert
4845 60 547

That is cool and all, but for sure this is a situation where one should strive to have this be 0% App and 100% built into Shopify, using nothing more than Liquid and Javascript. Now that it is established that unit prices are supported in at least a few countries too, that is for certain something that could be rolled out to everyone. As usual, the trickiest part of the equation remains tiered pricing where the more you buy, the cheaper it gets, or, for some industries anyway, the dimensions affect price in ways that are not so easy to pull off. It remains true though, that even in those cases one can easily capture dimensions, and alter pricing, and ultimately get orders flowing, without using external App code.

Custom Shopify Apps built just for you! hunkybill@gmail.com http://www.resistorsoftware.com
RM7
Visitor
2 0 0

Hello, I also need this feature urgently or possibility to set unit prices via csv upload.

jurek
Visitor
1 0 0

I am new to Shopify opening a online grocery store (in germany). So the feature is available but not accessable via the API.
I have a few thousand products so doing it manually is not an option. This feature is kind of crutial to migrate from WooCommerce to Shopify.
So API accessability of unitPriceMeasurement pls!

There are some duplicates of this question actually:

https://community.shopify.com/c/Shopify-APIs-SDKs/Cannot-find-unitPriceMeasurement-field-in-GraphQL-...

Benja
Visitor
1 0 0

II am a noob and have lost days trying to find a solution. Is manual update the only option? No CSV import? I need to update 5000 + SKUs regularly. Please help.
Should I migrate to Woocommerce? I need to find a solution fast. 

EYOND
Shopify Partner
4 0 9

@Josh Could you please give us an update on this? The feature seems to be urgently needed by some users.

Hißlinger
Tourist
4 0 11

Yes, we also need this urgently ;-´(

Gabe
Shopify Staff
16357 2587 3853

Hey Folks!

If you are not a German or French store and you need the Unit_Price Feature activated in your store we can activate that manually in the backend.

Simply let us know here or send us a ticket asking for the feature to be activated in the backend and we can do that.

Best,

Gabe | Social Care @ Shopify
 - War meine Antwort hilfreich? Klicke Like um es mich wissen zu lassen! 
 - Wurde deine Frage beantwortet? Markiere es als Akzeptierte Lösung 
 - Um mehr zu erfahren, besuche das Shopify Help Center oder den Shopify Blog

EYOND
Shopify Partner
4 0 9

@Gabe this feature is already enabled in our shopify admin area. However, we need this fields to be adjustable via the API.

Hißlinger
Tourist
4 0 11

Yes, please make this accessible via the REST API.

Currently it can only be set manually and with over 5,000 items at our site this is simply a disaster as this is a legal requirement in Germany. 😣

simonhaenisch
Shopify Partner
16 1 32

I'm maintaining an app and we also need to be able to retrieve `unit_price` and `unit_price_measurement` for each variant from the Admin REST API, specifically the `GET products.json` endpoint. It's a legal requirement in Germany to provide these for certain types of products.

It would be great if this was at least added to the Product API response, which is a backwards-compatible change. Being able to set this via the API also seems important for shop owners however is not a priority in our use case.

Adrian42
Visitor
2 0 2

Hey @Josh,

do you have any news here? We urgently need these fields in the API

Thanks

Gabe
Shopify Staff
16357 2587 3853

Hey Folks! 

I have a quick request for you guys: and that is, in order to fully understand your need, please fill out my quick questions below so that I can forward it to our product and developer teams. Please note that in order to be successful your feature request needs to have a good use-case, to be feasible, doable, non-costly, necessary from a business perspective, and a common request amongst many or the majority of merchants globally. I will then forward these on:

  • A clear problem description and its use-case:

 

  • Any current workarounds:

 

Gabe | Social Care @ Shopify
 - War meine Antwort hilfreich? Klicke Like um es mich wissen zu lassen! 
 - Wurde deine Frage beantwortet? Markiere es als Akzeptierte Lösung 
 - Um mehr zu erfahren, besuche das Shopify Help Center oder den Shopify Blog

Renars
Shopify Partner
284 31 332

Hey @Gabe 

Renars here from Matrixify app.

  • A clear problem description and its use-case:

Merchants are using our app to bulk import and export data from their Shopify store.
There are many cases where this is needed by merchants.

1. Mainly - the ability to bulk update this data.

Same as with other fields, the ability to bulk update it becomes crucial when the store has over a few hundred products.

2. Import this data when migrating from another platform to Shopify.

Other platforms, especially more custom ones, also have this data. But when the merchant is migrating to Shopify, there is no current way to migrate also the unit_price and unit_price_measurement fields into Shopify.

3. Duplicate, clone, or synchronize Shopify stores.

A lot of users use our app to duplicate, clone, or automatically sync their Shopify stores, and as it is from Shopify to Shopify then it should be expected that all Products data can be migrated over, but these details are missing from the migration/synchronization.

4. Synchronize data from suppliers.

Specific suppliers provide these details in their product files.
Merchants use our app to create automated, semi-automated, or manual imports from supplier data to Shopify, but these fields still need to be set manually in the admin.

5. Custom reports.

This data is also needed for custom reports that merchants can create using our app by exporting Orders or Products.

  • Any current workarounds:

At the moment, our app does not support the ability to import or export these fields which leads to frustration from merchants as they need to manually enter this data in Shopify Admin.
There are no workarounds for this, so we have no way to eliminate this frustration for our Merchants and Agencies.

---

I hope this information from us helps to implement the ability to read/write this data via the Shopify REST API or GraphQL.

Matrixify | Bulk Import Export Update | https://apps.shopify.com/excel-export-import | https://matrixify.app
Gabe
Shopify Staff
16357 2587 3853

That's great thanks a bunch Renars! @Renars 

Gabe | Social Care @ Shopify
 - War meine Antwort hilfreich? Klicke Like um es mich wissen zu lassen! 
 - Wurde deine Frage beantwortet? Markiere es als Akzeptierte Lösung 
 - Um mehr zu erfahren, besuche das Shopify Help Center oder den Shopify Blog

hugoh
Shopify Partner
6 0 0

Hi @Gabe !

Any news on this, 5 months after your reply? We also have a use case for a shopify to sage sync platform.

 

Thanks alot!

 

HunkyBill
Shopify Expert
4845 60 547

Amazing that Shopify makes us write an essay like we are twelve years old, to have a couple of values they have supported for many years (in Euroland anyway)... Seriously fun stuff. Like the API team has to scratch their heads at how to unleash the hounds on 2 values per variant.

Custom Shopify Apps built just for you! hunkybill@gmail.com http://www.resistorsoftware.com
Hißlinger
Tourist
4 0 11

We simply (and almost all other German Customers, because it it the law) need the Funktion to Edit the Base Price Flag & Base Price Unit via the REST-API.

Thats all.

FabianPG
Tourist
6 0 18

Hi Gabe,

I'm seriously wondering what can be uncelar here ... the unit price fields are legally required for all merchants in Europe to be kept up to date. You will be sued in no time if anything is wrong with your unit prices - there are agencies who do nothing but banging on merchants who make a small mistake in this.

Currently it is utterly cumbersome to manually maintain this data across the product catalogue.

Apps like Matrixify have no chance to help us improve on the situation, because they can't access the fields... and the bulk editor in Shopify also doesn't offer editing them.

Then, on top of just maintaining the product catalogue for use in Shopify itself, you typically also want to populate your products catalogue to platforms such as Google, Facebook, Pinterest, etc etc etc... also for this purpose it is extremely useful if you can pull the product data via the API.

 

So PLEASE acknowledge that these fields are part of harsh legal requirements for your European merchants. 

 

ACTUALLY it is 4 fields that need to be made available:

  1. Total product measurement
  2. UOM for the total product measurement
  3. Base measure
  4. UOM for the base measure

as you can see in the screenshot below:

Bildschirmfoto 2021-10-21 um 00.18.35.png

 

Thank you & Best Regards

Fabian

EYOND
Shopify Partner
4 0 9

At this point, I would like to agree with FabianPG and I would like to emphasize again that this is not a "nice-to-have" requirement, but a specific legal guideline within the EU:

https://ec.europa.eu/info/law/law-topic/consumer-protection-law/unfair-commercial-practices-law/pric...

Hopefully, the Shopify team can finally be convinced of the necessity of this request.

HunkyBill
Shopify Expert
4845 60 547

Never minding the sensibilities of European guidance here, this feature should have been rolled out to Shopify in general a decade ago. I have hundreds of merchants in my inbox that have contacted me since 2007 asking for unit pricing and sales on everything from welcome mats at the front door to the usual picture frames and signs on vinyl.

This issue has been ignored since inception, as being too niche for the effort required to overcome the mods to Shopify in general. Hopefully the newly minted CTO takes on the challenge and we all get unit pricing and sales sooner rather than later, with support from the API to maintain the values needed.

Custom Shopify Apps built just for you! hunkybill@gmail.com http://www.resistorsoftware.com
Benja-Moreno
Visitor
2 0 0

Hi Gabe, 

Thank you for looking into this. It is an issue that has made me turn in circles looking for a no code solution. 

To describe the issue briefly, it is the need to bulk update the "unit pricing measure" and the "unit pricing base measure" for product variants to be able to comply with the EU Directive 2019/2161 that requires the selling price and the unit price of all products offered by traders to consumers, to be clearly indicated in order to improve consumer information and to enable price comparisons. This is product information that is also available through Google's "Content API for Shopping" and is a requirement in some areas to get approval for google shopping.

The legal requirements for european merchants are described shortly if you follow this link: What is the aim of the directive?
This link shows the EU directive with details about the 4% fine on yearly turnover in case of failing to comply: Directive (EU) 2019/2161 of the European Parliament

From Google Merchant Help Center: 

Use the unit pricing measure [unit_pricing_measure] attribute to define the measure and dimension of your product. This value allows users to understand the exact cost per unit for your product.

These are the requirements you'll need to meet to show your product. If you don't follow these requirements, we'll disapprove your product and let you know in the Diagnostics page in your Merchant Center account.

https://support.google.com/merchants/answer/6324455?hl=en&ref_topic=6324338 

https://developers.google.com/shopping-content/reference/rest/v2.1/products#productunitpricingmeasur...

Benja-Moreno
Visitor
2 0 0

Hi, to describe it briefly, I guess it would be the need to bulk update the "unit pricing measure" and the "unit pricing base measure" for product variants to be able to comply with the EU Directive 2019/2161 that requires the selling price and the unit price of all products offered by traders to consumers, to be clearly indicated in order to improve consumer information and to enable price comparisons. This is product information that is also available through Google's "Content API for Shopping" and is a requirement in some areas to get approval from google shopping.

The legal requirements for european merchants are described shortly if you follow this link: What is the aim of the directive?
This link shows the EU directive with details about the 4% fine on yearly turnover in case of failing to comply: Directive (EU) 2019/2161 of the European Parliament

From Google Merchant Help Center: 

Use the unit pricing measure [unit_pricing_measure] attribute to define the measure and dimension of your product. This value allows users to understand the exact cost per unit for your product.

These are the requirements you'll need to meet to show your product. If you don't follow these requirements, we'll disapprove your product and let you know in the Diagnostics page in your Merchant Center account.

https://support.google.com/merchants/answer/6324455?hl=en&ref_topic=6324338 

https://developers.google.com/shopping-content/reference/rest/v2.1/products#productunitpricingmeasur...

magnalister
Shopify Partner
10 0 9

Why you don't provide unit-price as a meta-field for other app?

hugoh
Shopify Partner
6 0 0

Hello @magnalister 

 

unit-price and unit-price measurements are already defined in shopify's admin so why create an extra meta-field?

magnalister
Shopify Partner
10 0 9

Because we are waiting forever for getting base price through REST API. If it is so difficult for Shopify to make it possible, then Shopify can provide base price at least as meta-field so that all apps can read meta-field from it.

 

Unfortunately, Shopify doesn't want to understand how important is unit-price for European third party plugins and shop.

hugoh
Shopify Partner
6 0 0

If you're only asking for reading values you might use Storefront API. 

magnalister
Shopify Partner
10 0 9

@hugoh Didn't you read so much requests in this post to access unit price field from REST API. And you tell me, I am the only one!!! What I suggested was only a possible solution to make it faster to have this feature in REST API.

 

When we want to use Store Front API we should switch our App to a Sale Channel app. Our App is not a Sale Channel, and if we do that, we need to ask our 1000 Shopify shop owners to uninstall the old app and install a new sale channel app. This communication and implementation will could take for us 100 hours, but for Shopify to add new field could take some hours.

 

If you are really a new member in Shopify, please read the complete posts and check the possibilities a little more. If you are from Shopify, please inform your team how important this feature is.

 

Thank you

Gabe
Shopify Staff
16357 2587 3853

Hey Folks!

 

Just chiming in here and we are totally aware of the epic need in Europe for the unit price as part of the csv fields, as well as the bulk editor. We also know that the unit price via the REST API would solve huge pain-points that app partners are currently experiencing (like yourselves from Magnalister and Matrixify). We fully realise the importance of these features for the apps and are working hard to get this done!

 

We currently have a very large backlog of these requests and they are also in a queue of priorities from P5 to P1. Aside from the fact that the above three features are quite complex from a systems thinking perspective  as they go a lot deeper than the current live PPU features that you are already using i.e. there are a large amount of moving parts and connected modules in the core system that need to be considered and issues that need to be ironed out first by our product teams before these features can be implemented.

 

But rest assured folks, we have been pushing these items for a while now and we are hoping that in the next few months there will be some new developments coming your way!

 

Shopify is thinking of you and your needs so watch this space!

Gabe | Social Care @ Shopify
 - War meine Antwort hilfreich? Klicke Like um es mich wissen zu lassen! 
 - Wurde deine Frage beantwortet? Markiere es als Akzeptierte Lösung 
 - Um mehr zu erfahren, besuche das Shopify Help Center oder den Shopify Blog

FeedDonkeyApp
Shopify Partner
18 0 10

Hi,

 

Martin from Feed Donkey app

 

Why is this thread set as solved?  As far as I can see it isnt & remains a big problem for anybody who relies on the REST API and is trying to provide a full data service to DE and FR merchants

 

We fall into this category too & want to make sure that this limitation is eventually addressed

 

I understand there is always a dev queue, but also think the complexity argument is being way over-exagerrated here, this should have been solved a long time ago

 

Best regards

 

Martin

 

 

Feed Donkey app | Product catalogue feeds for ads | check us in the Shopify App Store apps.shopify.com/feed-donkey
FeedDonkeyApp
Shopify Partner
18 0 10
Hi, thanks but I don't think that's something that solves it in our case.

The only way that we can access customers product data is through the
permission scope granted on install

Any requirement for non native code isn't going to work as far as I can't
see

Best

Martin
Feed Donkey app | Product catalogue feeds for ads | check us in the Shopify App Store apps.shopify.com/feed-donkey
Frank74
Tourist
4 0 3

"In den nächsten Monaten ..."
Bis dahin sind verzweifelte bisherige Shopify Anwender zu Woocommerce usw. gewechselt. Das kann ja nun nicht das Ziel von Shopify sein. 
Bin zwar verzweifelt, da ich über 2000 Produkte händisch ändern muss und dabei gewiss eine abmahnfähige Fehlerquote entsteht, aber noch habe ich Hoffnung. Vor allem weil der Gründer von Shopify ja ein Deutscher ist und sich der rechtlichen Brisanz durchaus bewusst sein sollte.

Ryback
Shopify Partner
7 0 4

Any news on this topic?

The last official shopify-post from gabe is already 4 month old.

 

I was hoping that the "shopify editions summer 2022" would bring news about this topic, but unfortunately there was none.

 

Find it very strange, that it took for a 3 year old feature so long to put it in the rest-api and graphql-api...

Menny
Shopify Partner
13 0 3

Hey there! any update with this one?

MarieH
Visitor
2 0 1

Hi @Josh, hi @Gabe,
I've read the entire thread, and it seems that this issue hasn't been solved yet. Is there any update on this topic? It's been a few months now, and I believe it's still a priority for everyone in this channel!
Thank you!

Gabe
Shopify Staff
16357 2587 3853

Hey Folks!

 

Not much to report from the developers currently, as the Unit Price is still in beta status. In case it helps, you can now upload unit prices in bulk via csv using the Price per Unit App. I've attached a template csv file from the app.

Gabe | Social Care @ Shopify
 - War meine Antwort hilfreich? Klicke Like um es mich wissen zu lassen! 
 - Wurde deine Frage beantwortet? Markiere es als Akzeptierte Lösung 
 - Um mehr zu erfahren, besuche das Shopify Help Center oder den Shopify Blog

simonhaenisch
Shopify Partner
16 1 32

How can such a simple feature be in beta status for 3 years already???? (many more comments I want to add but i better keep quiet)

Ryback
Shopify Partner
7 0 4

Sadly, it looks after 3 years that Shopify has little interest in this feature to implement clean in all APIs. Probably because it is only limited to Germany and France.

 

We`re pretty new to Shopify and currently in the final steps in migrating from our old shopware shop.

So far there were a naturally few obstacles but whats going with the price per unit (or not going on) is beyond everything.

I hope we will never need another feature for legal reasons in time.

Menny
Shopify Partner
13 0 3

this is an important feature for me too 

Menny
Shopify Partner
13 0 3

Do you think in the feature there will be an option to also sell items by unit. Like selling meat/fruits by the LB for example?

Gift-o-the-Jab
Navigator
358 23 95

This was already sent up as a request to the feature requests backlog.

We'll see how that develops as the dev and product teams have to weigh up the PPU API factors of viability, global demand, feasibility, system stability, all moving parts, and so on and so forth...

It may be a yay or a nay. Drücke die Daumen!