REST api and magento