Does anyone have a reliable way to map the individual Item Cost from NetSuite to Shopify? I have both Matrix and Individual products for this application.
Gabe, were you ever able to get this working? I am looking to do the same thing.
The Shopify API documentation seemed to hint at importing cost via the inventory update API. I tried including a column for cost in my item inventory export saved search, and mapping it in the Netsuite to Shopify inventory flow but had no luck.
Hi Mike, We have a flow to sync the products along with their price from NetSuite to Shopify - https://docs.celigo.com/hc/en-us/articles/228220687.
You can also refer to Shopify API documentation for products.
Hope this helps.
Mike
The answer is no. There still isn't a way to map the cost over to Shopify. If you look at a product in Shopify and put ".json" at the end of the URL you will see there is no "Cost" or "Cost per item" field visible. This is likely due to Shopify not providing access to that endpoint.
So it's not a Celigo issue - it's a Shopify issue.
I think I just figured it out!!!! Looks like the Celigo and Shopify API are not communicating with accurate returns from Shopify on the available fields. I will put in a ticket for it and see what they say.
In the interim - try this: Map your "Cost" field you set up from the NetSuite Saved Search and in the Integrator Mapping for Product or Matrix Items manually enter "product.variants[*].cost" and hit preview - I am going to test it on my end as well.
Here's a link on the Shopify side showing the "cost" data: https://shopify.dev/api/admin-rest/2022-01/resources/inventoryitem#top
Like I said, I just added the "product.variants[*]." to the "cost" and hit preview - and it showed up in the Preview!!
I found a different way of doing it as well after digging back in. I like your method too - wonder if one method is better than the other to use?
@gabeparr I noticed that API documentation and tried adding it to my inventory flow but without luck. Then I tried something similar to you, based on the structure in that documentation. I mapped my Cost column to product.variants[*].inventoryItem.cost and the preview json looks the same as compared to the API documentation. However, my cost was not imported after running the flow and checking on an updated item.
@hairball.io I will try your method next and update how it goes!
I initially tried product.cost, but I never tried product.variants[*].cost. I'll give it a go - but that does not match API documentation from Shopify. Curious if you verified that the costs actually import correctly like this? Here's how the documentation looks:
It looks like you created a standalone flow for updating item cost, can you confirm that that's how you did this?
I apologise , I misunderstood the request as mapping price . Cost is part of Inventory Item API and inventory flow is utilising inventory levels API. Both inventory and product flows won't be able to support cost. As suggested by Hairball.io , you can try a custom flow to sync cost.
@mikemeyer @sreevaniamara @hairball.io
Can confirm - the change I made to the mapping works as I set up! Just modified the record in NetSuite because we are running Delta on the flow and POOF! There's the Cost!!!! No extra flow is required...
SWEEEEET!!
Well sort of - now I just have to do a minor update to 12K products so the flow can see modification date change for all of them.
@mikemeyer @sreevaniamara @hairball.io
Can also confirm the change works on child items for Matrix Flow as well!!
Yeesh - now on to modifying 12K products!! WHeeeeee!!
Cheers!! This works perfectly, even though according to documentation it probably shouldn't - lol.
If you want to leave your products flow as a delta flow, you could probably just set a custom date for the flow and push it back to something like 1/1/2000. Might save you a headache in NS :)
Good call on the backdating on running the flow... Glad the fix worked for you even though it shouldn't - LOL
Any luck updating this for GraphQL? The syntax in the feed mapping is different, so not sure how to target the cost field. I've tried mapping to a destination field of "cost" and "costPerItem", but haven't been able to get that value to post. Worried that this loophole has been closed in the GraphQL API.
Looks like we have this same issue now that we have to swap over to GraphQL. I've been trying to work with Celigo staff on this, but their internal testing framework is set up differently than our configuration.
e.g. Integrator internal version of the mapping shows an "inventoryItem" field and has the SKU, weight, and cost fields nested under that. Ours doesn't even have the "inventoryItem" field within the flow...
As to theirs showing "weight" nested under that inventoryItem segment - that conflicts with the current suggestion of using metafields...
SMH... Can we get things updated so when customers are requesting staff help we can all be on the same page as to the design of these "out of the box" flows Celigo is creating please?
Oh, and any insight the community can provide about how to get "cost" into the new GraphQL flow would be appreciated.
Sorry, should have updated. We have this mapping working again with GraphQL, here's how we set it up (along with the correct mapping for item weight and weight units):
This solution did not work for us @Jason_C for the weight and weight unit. See screenshot of what we had to implement to make it work. I am not sure that my configuration needs to be updated or customized again to reflect what you show - but that is a larger point worth addressing.
Sure, it would be nice if these "changes" and how Celigo universally implemented the mapping views on your system. Still, a lot of "patching" is going on right now, and we only have a few weeks left to tie off all these loose ends. Hopefully, all these "small inconsistencies" between all users of the Shopify-NetSuite Product flows changing to GraphQL will reconcile at some point, and we can all work off the same foundation.
Also the "cost" value you show - I have an open ticket on this (241779) where applying that field and ensuring the Saved Search was written as noted "$.variants.[Cost (Variant)] = cost" did not perform as expected nested under "inventory item" which was not even present in the flow at the time and I had to add it. An additional formula line was added to our Saved Search stating, "CASE NVL({parent},'0') WHEN '0' THEN{itemid} ELSE SUBSTR({itemid}, INSTR({itemid}, ' : ', -1) + 3) END" to "This formula is essential because, before syncing the field value, we need to search for the SKU first. This ensures that the parent SKU is not included and that the flow only carries the SKU of the variant items." per Integrator.IO support staff.
So while some may be having success, depending on what they are mapping/syncing, we are far from a robust solution, without unification/reconciliation of mapping/flows.
Thanks for the update.
Interesting. I saw reference to that solution, but does posting those values to a metafield with a custom name space actually work to have the weight on the item record in Shopify?