App reviews, troubleshooting, and recommendations
I have created a Shopify app using Remix. In my api.getProducts.jsx file am trying to create an endpoint that returns the first 10 products of the shop. But from a public url. This is my actual (not-working) code:
import shopify from "../shopify.server";
import { json } from "@remix-run/node";
export async function loader({ request }) {
const { store } = await shopify.unauthenticated.storefront(request);
const response = await store.graphql(`
{
products(first: 10) {
nodes {
id
title
description
}
}
}
`);
const parsedResponse = await response.json();
return json({
products: parsedResponse.data.products.nodes,
});
}
Thanks for the reply!
In my .env I only have my Shopify api key, where can I found the api secret?
Apart from that, I need to use for this case, graphQL, how can I use it from here without getting a Forbidden error
Error
Hey Community! As we jump into 2025, we want to give a big shout-out to all of you wh...
By JasonH Jan 7, 2025Hey Community! As the holiday season unfolds, we want to extend heartfelt thanks to a...
By JasonH Dec 6, 2024Dropshipping, a high-growth, $226 billion-dollar industry, remains a highly dynamic bus...
By JasonH Nov 27, 2024