Devdocs: Feedback on page: /guides/v2.4/rest/tutorials/orders/order-issue-refund.html

Created on 13 Oct 2020  路  10Comments  路  Source: magento/devdocs

General issue

Description:

I am using magento 2.3.5. I need to offline partial refund through rest api. [I used POST /V1/order//refund | Issues an offline refund ] URL : https://devdocs.magento.com/guides/v2.4/rest/tutorials/orders/order-issue-refund.html

My code

$jsonValue = array ('items' =>array (array ('order_item_id' =>$item_id,'qty' => $order_qty)),'notify' => true,'arguments' => array ('shipping_amount' => 0,'adjustment_positive' => 0,'adjustment_negative' => 0,'extension_attributes' => array ('return_to_stock_items' => array ($item_id))));

                $jsonValue =  json_encode($jsonValue);
                $order_url = $url."rest/V1/order/".$order_id."/refund";
                $setHaders = array('Content-Type:application/json','Authorization:Bearer '.$adminToken);
                $che = curl_init($order_url);
                curl_setopt($che, CURLOPT_CUSTOMREQUEST, "POST");
                curl_setopt($che, CURLOPT_RETURNTRANSFER, true);
                curl_setopt($ch, CURLOPT_POSTFIELDS, $jsonValue);
                curl_setopt($che, CURLOPT_HTTPHEADER, $setHaders);
                $resultcredit = curl_exec($che);

Problem : in body I have pass order_item_id' . I have pass value of item_id which I get order thorugh order api. I dont understand why full order go to in closed status.

Please suggest me full :
1) which value will pass in order_item_id ? where I get this?
2) which value will pass in return_to_stock_items ? where I get this?

Please help us so I will solve partial refund.

Thank you for taking the time to report this issue!
GitHub Issues should only be created for problems/topics related to this project's codebase.

Before submitting this issue, please make sure you are complying with our Code of Conduct:
https://github.com/magento/devdocs/blob/master/.github/CODE_OF_CONDUCT.md

Issues that do not comply with our Code of Conduct or do not contain enough information may be closed at the maintainers' discretion.

Feel free to remove this section before creating this issue.
-->

Most helpful comment

Thanks I have place new issue on github
https://github.com/magento/magento2/issues/30500

All 10 comments

Hi @krunalpanchal1607. Thank you for your report.
To help us process this issue please make sure that you provided sufficient information.

Please, add a comment to assign the issue: @magento I am working on this


@krunalpanchal1607 - Issues on DevDocs are for additions or improvements to the documentation, we do not answer requested for help on these. I see that you have raised the same issue on the #general Slack channel for MCE, which is the best and most appropriate channel to get advice and help. Therefore I am closing this issue.

This issue is more important for me so please dont closed it . I am remove this issue in general slack

Sorry but this is a request for help. We do not deal with help requests on DevDoc issues.

I am checking all document of magento 2 rest api but not get my answer and I have done same as document but issue is not solve.

I am doing same as magento 2 document. I am develop many site and rest api
for this but this type of issue not come I know very well for rest api. So
please suggest me or open my issue

Hi @krunalpanchal1607 , thank you for your feedback and I have consulted the other DevDoc Maintainers on your comments. However, it doesn鈥檛 seem like your issue is related to Magento DevDocs documentation. To get answers to your questions, check the Magento Support Knowledge Base, forums, or Stack Exchange. To report Magento 2 issues with code, see the Magento 2 GitHub. To suggest new product features and enhancements, see Magento features and improvements. Thanks for taking the time to create a GitHub issue for docs improvement! Keep us updated with your potential solution so we may update documentation to be clearer (or you can create an issue for it yourself!)

hello sir I don't get my answer in magento slack channel. Please suggest me .I think this is bug in magento 2 for partial offline refund api. Not do partial refund through rest api.

Your comment "I think this is bug in magento 2 for partial offline refund api" - if you believe this is a bug in the code then you need to raise an issue on the Magento2 Github : https://github.com/magento/magento2

Thanks I have place new issue on github
https://github.com/magento/magento2/issues/30500

Was this page helpful?
0 / 5 - 0 ratings