I’ve been trying to set up my site to accept product orders, and I’m having problems with Snipcart. Has anyone used it who can provide some help?
All of my test orders are failing except for two of the products. When I look at the error log and the security flowchart at Snipcart, the problem seems to be that:
- Snipcart gets a Content-Type from the product’s URL, and the Content-type is either JSON or HTTP.
- I’m assuming that the Content-Type is JSON because I’m getting a JSON error in my error log. Snipcart is trying to match the product code and price in the cart to the product code and price in the products.json file on my site. And they don’t match.
- When I look at the products.json file on my site, it only contains two products in it (and those are the two products that I can successfully test-order with Snipcart. All other product orders fail (because they aren’t in the products.json file).
- Which brings me to the question: how is the products.json file created? I’m guessing that Sparkle creates it? But have I broken the model by having products on 30 different pages? It looks to me like the file was created from a single product file (but I don’t even know how Sparkle chose which product page to use to populate the file). Or maybe Snipcart creates the file when I import pages into Snipcart so it can build the inventory list of products, but I wouldn’t have expected Snipcart to be able to create files on my site.