A space to discuss GraphQL queries, mutations, troubleshooting, throttling, and best practices.
HTTPError: Response code 400 (Bad Request)
at Request.<anonymous> (/Users/..../node_modules/got/dist/source/as-promise/index.js:118:42)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5) {
code: 'ERR_NON_2XX_3XX_RESPONSE',
shopify.order.list({ limit: 5, fulfillment_status: "unfulfilled" })
.then((orders) =>
orders.forEach(order => {
console.log(order);
var trackingNumber = getTracking();
const fulfillment = {
tracking_number: trackingNumber,
notify_customer: true
}
const fulfill = shopify.fulfillment.create(order.id, fulfillment)
console.log('fulfill ======>', fulfill)
})
).catch((err) => console.error(err));
Can someone guide me on what's going wrong here?