GraphQL return a fufilled item

ykyuen
New Member
7 0 0

Hi all,

I wonder if there is a GraphQL mutation for returning an fulfilled item. The only mutation i found is the refundCreate and it has a RETURN option in the RefundLineItemRestockType.

I could successfully perform a Refund the fufilled item is doesn't mark as returned.

sc-2021-01-27-12-05-23.jpg

---

And if i click the refund btn in the order detail page, it said there is no more item available for return. so i guess there should be no more fulfilled items.

sc-2021-01-27-12-05-59.jpg

---

Here is the mutation input i used for refundCreate

    // Refund/Return item
    const refund = {
      orderId: `gid://shopify/Order/XXXXX`,
      refundLineItems: [
        {
          lineItemId: `gid://shopify/LineItem/XXX`,
          quantity: 1,
          restockType: 'RETURN',
          locationId: `gid://shopify/Location/XXXXX`
        }
      ],
      transactions: [
        {
          amount: 100,
          gateway: 'bogus',
          kind: 'REFUND',
          orderId: `gid://shopify/Order/XXXXX`,
          parentId: `gid://shopify/OrderTransaction/XXXXX`
        }
      ]
    };

---

So is there anyway i could mark the fulfilled item as RETURNED in the order detail page as show below thru API?

sc-2021-01-27-12-11-30.jpg

---

Thanks~

Regards,
Kit

0 Likes
ykyuen
New Member
7 0 0

Another problem i found is orginally the order i show above is $634.99 and i refund $100, so the remaining amount is $534.99 which is correct in the order detail page.

But in the order listing, the Total amount only contains the Shipping fee $5.99.

sc-2021-01-27-12-29-55.jpg

0 Likes