Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [rest]

Denotes questions related to the REST API on Magento

1
vote
1answer
780 views

Add new customer address REST API : Magento 2

Is there is an API to add new customer address without admin token?
2
votes
1answer
472 views

Return Shipping Methods in Store REST API

Is there an API endpoint to return all shipping methods and carrier codes used in the store?
2
votes
1answer
454 views

Price In Configurable Product is 0 in REST API Response : Magento 2 [duplicate]

In Configurable products REST API, the price response is 0, so I need to get ride of it. I knew later that configurable products prices are displayed in the web store as the smallest price listed in ...
1
vote
0answers
265 views

How to get tax Rate details of sales order in Magento2 using rest api?

I want to know the tax rate information of particular sales order. I am fetching the sales order information from Mangento2 rest API using the following URL : http://magentourl/index.php/rest/V1/...
3
votes
1answer
1k views

Add Pagination To Catalog Search Results REST API: Magento 2

I am using this API for search: http://domain.com/index.php/rest/V1/search?searchCriteria[requestName]=quick_search_container&searchCriteria[filterGroups][0][filters][0][field]=search_term&...
0
votes
1answer
48 views

How to find valid values for fields in the REST API

I have been searching for documentation regarding the REST API. All I have found is the Swagger page. It gives a good overview but it doesn't provide any information about valid values for ...
1
vote
2answers
1k views

Customer session for logged in customer by token based authentication

We are using token based authentication over rest api from that resource /rest/V1/integration/customer/token?username=USER_NAME&password=P@$$WORD to consume magento rest api web services. We ...
1
vote
0answers
170 views

oauth_problem=Consumer+key+has+expired

Hello Magento Community, I am trying to integrate the Magento Rest API in my App. But while doing the OAuth authentication for request token I am getting error as Consumer Key has Expired. I have ...
1
vote
1answer
70 views

Where is webapi.xsd located

I have been trying to access a REST API end point that results in a 404 Not Found. I have come across documentation that explains the endpoints have to be configured in the webapi.xsd file. I have ...
1
vote
1answer
747 views

REST API Access Token Issues

I am trying to use the Magento REST API for a client to get details of customers, and orders, etc. I have setup a REST Consumer and I am trying to obtain an oauth access token and having issues. I ...
3
votes
1answer
430 views

Magento 2 : Wrong order created and updated date in rest api response

I am fetching the orders using Magento 2 REST api services. I am using IST timezone the dates saved in the database are in correct timezone. I have set timezone to "Asia/Kolkata". On customer ...
0
votes
0answers
588 views

Add value for custom quote item attribute using REST api

I want to add value for custom quote attribute using rest api. This attribute is not a product attribute. I have created a database column in quote_item table. Also created the plugin on class Magento\...
4
votes
1answer
3k views

Magento2 How to set expiration time for token

I Have generated a token for API calls by using following code : curl -X POST "http://magento2.ce/rest/V1/integration/customer/token"\ -H "Content-Type:application/json"\ -d '{"username":"john@...
2
votes
0answers
168 views

Catalog Search gives different results every request : Magento 2

I did search several consecutive times for catalog search in the search box in the header of the store, but every time gave me different results as following: Also, I can see this difference when use ...
0
votes
1answer
330 views

Configurable Product Price is 0 in API Response

Dears, Why Configurable products price is always displayed as 0 in rest API response like (sku related to magento 2 sample data): http://domain.com/index.php/rest/V1/products/MH01 Although it is ...
1
vote
1answer
838 views

Magento 2 RESTful API update category

I am using Magento 2.0.11. I would like to use the RESTful API (HTTP:// magento2URL/index.php/rest/V1/categories/(category ID)) to change the "Is Active" attribute of one category from True to ...
1
vote
1answer
399 views

REST Api product creation with global attributes

I'm trying to add new products to a Magento 2.1.7 and noticed some strange behaviours when it comest to global attributes (special_price for this example), found a workaround (kind of...) and was ...
1
vote
1answer
470 views

Magento2 Get website_ids in product get api

Magento2 get website_ids in product get api means product is assigned to which websites. This is issue generated in github: https://github.com/magento/magento2/issues/5773 , but there still not any ...
4
votes
1answer
4k views

POSTMAN rest and Magento-rest with Oath

POSTMAN rest client with magento REST api with Oauth. How to get Token and Token Secret? Magento REST API, how i will get token and token secret to be fill in Postman REST request. I have only ...
1
vote
1answer
1k views

How to create and use REST API for mobile app?

Am totally new to the magento and API's. I have gone through the Magento Rest Api Documentation. I have created roles and users for rest api but in the documentation it is like http://magentohost/...
0
votes
1answer
486 views

Sign Up with Customer Image attribute REST API : Magento 2

I added image attribute in customer create account, edit account in Setup/InstallData.php as following: public function install(ModuleDataSetupInterface $setup, ModuleContextInterface $context) {...
1
vote
1answer
50 views

Session in api-functional tests isLoggedIn always returns false

I have a function in an API call that checks $this->session->isLoggedIn(). The session-object is injected via the consturtor. Now I have to write an api-functional test. But I just can't login ...
0
votes
1answer
808 views

Get Latest Products REST API

How can I get latest products as a REST API to display in mobile application home screen ?
8
votes
2answers
6k views

Magento 2 Api Getting Error '%fieldName is a required field'?

I am not getting result (id) while using POST method using url is rest/V1/hello/test/3 Screenshot: I have followed this link For Reference Please Click Here 1) webapi.xml <?xml version="1.0"...
1
vote
1answer
1k views

Retreive ALL Product details in Search REST API

Dears, I am using this API in search: GET http://domain.com/index.php/rest/V1/search Parameters: searchCriteria[requestName]= quick_search_container searchCriteria[filterGroups][0][filters][0][...
0
votes
1answer
676 views

Magento 2: How to create API rest for users CRUD

I know that Magento has CLI for creating new users, but I need to do that via API rest. And extending all CRUD functionalities. So I tried to create a new module for do that, but it's not working: ...
3
votes
1answer
904 views

Sign Up With Avatar REST API Validation Error : Magento 2

I have this code for image attribute (avatar). app/code/Ibnab/CustomerPut/Setup/InstallData.php : <?php namespace Ibnab\CustomerPut\Setup; use Magento\Framework\Module\Setup\Migration; use ...
2
votes
2answers
1k views

Magento 2 Rest API: Generate Auth Token for guest user

I need to generate authentication Token for guest user. I have checked in documentation, we can only generate Auth Token for customer and admin. Other resource can be accessed using anonymous role. ...
2
votes
0answers
230 views

Magento 2 REST API: What's the difference between carts and guest-carts?

Our team is developing a store using Magento 2 as the backend, with a decoupled client-side layer using Node.js/Express/React/Redux. So obviously we are relying heavily on the REST API, which is far ...
2
votes
1answer
517 views

Return order details in REST API Magento-2

I am writing a custom API which will use a customer token in authorization header and will able to fetch the order details. Below is my code: File : CustomerOrderRepositoryInterface.php <?php ...
1
vote
1answer
329 views

Sort Products REST API : Magento 2

I did a sort for product by price through API: http://domain.com/index.php/rest/V1/search?searchCriteria[requestName]=quick_search_container&searchCriteria[filterGroups][0][filters][0][field]=...
0
votes
1answer
538 views

API Access denied and 403 error

api/rest/customers is not working. I am Error 403 access denied though its working for products but not for orders.
1
vote
2answers
132 views

Unable to create customer using curl command

I am new to magento. I am facing an issue will trying to create customer using curl command. I am passing the correct json values as customer data as well, but still getting decoding error.Can some ...
4
votes
1answer
643 views

I need to add a extra field in product rest api response - Magento 2

I want to add a field "slider" in /rest/V1/products/:sku I created a custom module and in my di.xml i have added the following code <?xml version="1.0"?> <config xmlns:xsi="http://www.w3....
0
votes
1answer
754 views

Magento 1.9 Order Rest API Order Data

Using magento rest API i can see the data of product, category etc using https://magentohost/api/rest/products, Here is can see list of products but when i access https://magentohost/api/rest/orders ...
2
votes
3answers
824 views

Magento 2 - Category Save Event is not called when save category via rest api

I have created one observer CategorySaveAfter.php file in my custom module. And calling this observer on catalog_category_save_after event define in events.xml But somehow its not calling when i ...
5
votes
3answers
1k views

How to Get Customer data by telephone number in Magento2?

I have a telephone number which is given in Default address..by using this telephone number i need to get Customer Full data.Data like customer id, customer full name..etc
0
votes
1answer
1k views

Magento 2 Rest API: getting error “Invalid attribute name: %1”

Trying to get product with id using rest api search criteria: Request: http://magento_host/rest/V1/products?searchCriteria[filter_groups][0][filters][0][field]=id&searchCriteria[filter_groups][0][...
0
votes
1answer
323 views

Consistent 403 Error from REST API on v 1.9.3.2

The Setup I've been through every post I can find on this and still no luck. I've got code for authorizing with and connecting to the REST API. In a test environment running 1.9.1.1 this all works ...
3
votes
1answer
1k views

Magento2: Save Product Data for global scope using Rest API

I am trying to add product using Rest API. Adding product is working fine. But I am facing issue in assign in the product information only for Default values instead of copying data for store view. ...
1
vote
1answer
101 views

How to add Unirest to Magento 1.9.3.2?

I am trying to integrate Prompt Cloud API with magento. For it the basic requirement is to install Unirest library. I am trying to install using composer: composer require mashape/unirest-php And ...
2
votes
1answer
4k views

Magento 2 REST API returns only default category and its children

I am using "rest/V1/categories/" (Magento 2 Rest API). In documentation(devdocs.magento.com/swagger/#) it says "Retrieve list of categories" but it only returns default category(and its all children) ...
3
votes
4answers
6k views

Magento 2: How to generate Product URL Key when creating Product from Rest API?

I am creating Product in magento usign Rest API. Using the below format: { "product": { "name": "Product Name", "sku": "product_name_1498227094", "attribute_set_id": "18", "status": 1, "visibility": ...
1
vote
1answer
488 views

Unit test case for custom module REST API

I wanted to write unit test case for custom REST API in magento2. I have already gone through the : http://devdocs.magento.com/guides/v2.0/get-started/web-api-functional-testing.html I am getting ...
2
votes
1answer
681 views

Magento custom attribute over the REST API

I tried to get full list of order item attributes by this url: api/rest/orders/25/items . There are: "item_id": "62", "parent_item_id": null, "product_type": "simple", "sku": "...
5
votes
1answer
4k views

Magento 2: How to authorize REST API call of customer after login?

I am using rest API to login in customer account usig the below URL and details: URL: https://magento.host/index.php/rest/V1/integration/customer/token Header: "Content-Type:application/json" Data: "{...
3
votes
0answers
167 views

Magento - Create order using REST API

I need to create place order using REST API. I want to help someone to create API. If you have any reference URL for perfect code please let me know.
1
vote
0answers
523 views

Magento 2 API - Update Product Custom Attribute to Blank/Null

I am trying to update a product via the Magento 2 Rest API. If an attribute already has a value I can update that value with another value with no problems. However if I want to delete the value and ...
1
vote
0answers
853 views

Injecting Guzzle with Parameters Magento 2

Writing some REST API bits and going to use Guzzle, which I have used many times before. The issue I am coming across is, I know Guzzle has to take the configuration via parameters when constructing ...
0
votes
1answer
48 views

Front End and Backend Login Doesnt work Magento 1.9.3

My magento site is at this link: http://frisbeemarketing.com/mom2b/customer/account/login/ the login page does not work and it does not send an error it just reloads It seems like a problem with ...