free
web stats

Fill the form & Get Installation Support

Connect With Us





captcha

Connect With Us





captcha

How to get request post params from rest webapi in Magento 2?

While you’re working with the REST API in Magento you can retrieve the Rest Webapi Request Parameters.

Magento has its own OOTB Webapi module that is dealing with Rest API functionality.

Required Class, Magento\Framework\Webapi\Rest\Request

In the above example, ‘paramerer_name’ is your actual parameter name to retrieve the value from the request.

If you want to get all the parameters for the Rest API,
$this->request->getParams();  print the all list of key & value for the request parameter.

Was this article helpful?
YesNo
Fill the below form if you have any Magento programming need.




captcha