All Questions
Tagged with magento-2.1 rest-api
134 questions
0
votes
1
answer
2k
views
Magento 2 - Custom REST api POST method not working
I have created a custom rest api module. When i am using GET method it's working fine. But when i am trying to use POST method it giving below error
Request does not match any route.
Does anyone ...
3
votes
1
answer
223
views
invalid date when adding product with custom options(datetime) using REST API
I have a product with a custom option DateTime filed in product options
When I try to place an order using rest API. My order array is given below
$order = array (
'cartItem' =>
array (
...
0
votes
0
answers
692
views
Magento 2 Rest API return multiple interface class
On the Magento 2, I want to custom return object on my custom rest API, I have code like this on the Hz\Clients\Api\TransactionInterface.php
<?php
namespace Hz\Clients\Api;
interface ...
2
votes
0
answers
205
views
Magento2 Mobile SSO - OAuth-based authentication
I have been asked by a mobile dev to provide Magento 2 API to create a single sign-on application for my store. I have provided this info:
• curl -X POST "https://example.com/rest/V1/integration/...
2
votes
2
answers
3k
views
Magento 2 : how to change order status processing to complete using Rest Api
Any option to update order status processing to complete in Magento 2 using Rest API.
1
vote
2
answers
4k
views
Rest API import product Magento2
I want to add a product using REST API but don't know how should I do.
could you please help me what should I do? Magento 2.1 I use. this is the code that i used:
{
"id": 989898989989989898,
"...
2
votes
0
answers
231
views
Get and Add like(Favourite or Unfavourite) product in Magento 2 Rest API With URL?
Get Favourite product in Magento 2 REST API with URL?
And Add to Favourite in Magento 2 REST API with URL?
1
vote
2
answers
57
views
Custom Customer Attribute not being read from Request
I'm trying to add a new Custom attribute to the Magento customer model, and I think that I've set everything up correctly from what I've been able to scour off of this website & google, but I'm ...
0
votes
1
answer
262
views
How to change the status value in orders api?
In the orders api of Magento 2, I'm sending status parameter as completed.
But I have custom status as "ProdCompleted.
So everytime I get status="completed" That's why I want that if api get ...
1
vote
2
answers
5k
views
How to create custom API for company and customer creation in Magento 2
I want to create a company/company admin-user in Magento 2 (as what it does from the front-end/back-end panel) via a single API call.
Right now am doing with two API calls
First is creating a ...
1
vote
1
answer
504
views
Accessing Admin data from Magento 2.1 Rest API
I have integrated laravel 5.5 with magento 2.1
i-e: My magento installation works on http://magento.me
and my laravel part works on http://magento.me/laravel-panel
When so ever my customer is logged ...
0
votes
0
answers
70
views
How to show quote_id in response of /carts/mine/totals API in magento-2.1?
I want to show quote_id in response of /carts/mine/totals API in magento-2.1. Anybody guide me.
3
votes
3
answers
2k
views
Magento 2 swagger-ui error
I trying this url http://192.168.1.67/isac/swagger but I got this error below
500 : {"message":"Internal Error. Details are available in Magento log file.
Report ID: webapi-5bfe5e3ac4100"} http:...
4
votes
3
answers
8k
views
where to find Magento 2 API docs?
Finally I found out the magento 2 api endpoint for all products as below
rest/V1/products?searchCriteria[pageSize]=20
but I need more detailed docs about api endpoints which I coudn't find out yet. ...
4
votes
2
answers
3k
views
How to get invoice_Id or invoice in Magento2 after order is placed using REST API
After order is placed i am getting order_id and how can i get invoice of placed order (or) invoice_id after order is placed using Magento REST API.
1
vote
1
answer
963
views
Why Order Api is too slow in Magento-2.1?
When I show order history using this API
/rest/V1/orders/mine?searchCriteria[filter_groups][0][filters][0][field]=customer_email&searchCriteria[filter_groups][0][filters][0][value]=abc@gmail....
1
vote
0
answers
268
views
POST /V1/order/:order_id/invoices,it gives wrong response in magento-2.1?
Suppose I have two products in order,one is simple product and other is bundle product.When i generate first simple product invoice using item_id of simple product using this body:
{
"capture": ...
2
votes
1
answer
1k
views
How to create partial invoice using rest API in Magento-2.1?
I have one order, this order is having 3 items. I want to create different invoices of different items using Rest API. It is possible using the admin panel in Magento-2.1, but not using rest API. How ...
2
votes
0
answers
485
views
"Unable to save Stock Item issue" when I try to create multi-able simple products via RESTful API
I m using Magento2 API to create a configurable product, So I need to create numbers of the simple products first, but wired thing happened, some of the products have successfully created, but most of ...
1
vote
1
answer
698
views
Magento 2 Customer Rest Api Token error for some users [weird problem]
We have a mobile app for magento 2 which we communicate with magento 2 server using Rest api.
Our intent is to get customer access token by below request
https://magento.host/index.php/rest/V1/...
1
vote
0
answers
24
views
What is effect on /V1/order?searchCriteria api,when i delete some customer from magento admin panel?
I have some issue in rest/V1/orders?searchCriteria API.If I deleted all customer from admin panel,then what is effect on rest/V1/orders?searchCriteria API.When i call this API it give response:"...
0
votes
1
answer
704
views
Access token expires after 1 day
I am using the Quickbooks API for my application and I have used
https://intuit.github.io/QuickBooks-V3-PHP-SDK/authorization.html
generate-oauth-2-0-tokens for token generation.
The token is created ...
1
vote
1
answer
1k
views
How to filter Multiselect in Magento 2 search Rest API?
I am using magento search rest api. Now i can filter attributes like neck, sleeve, etc.., but i need to give multiple values for same attribute (like mulitple select)
My Request:
rest/V1/search?...
0
votes
1
answer
388
views
I want to some attributes in response of /V1/products/:sku api.How can be get specific data in this api?
When I call /V1/products/:sku,It give response like:
{
"id": 12,
"sku": "SL-LS",
"name": "Long Sleeve",
"attribute_set_id": 4,
"price": 0,
"status":...
1
vote
0
answers
47
views
How to display attribute value label instead of numeric value on response of /V1/products/:sku and /V1/products/?searchCriteria?
I have one multi-select attribute(filter_cuff). Its value is Single Button Cuff,Two Button Cuff,Single Button Rounded,Double Button Rounded. When I call /v1/products/:sku API, it shows response like:
...
0
votes
1
answer
218
views
How to change Order-Status with custom-order-status(Ready To Dispatch) using rest API in magento 2.1?
I have one custom order status(Ready To Dispatch).I want to change order-status of order using rest api.Please help me i don't know what api is used?
2
votes
0
answers
430
views
Magento 2.1: How to get attribute value as text in response of product rest api
I have created a custom attribute "color" and it has the values Red, Green, Blue. When I call /V1/products/:sku it shows the product details and also shows the custom_attributes{"attribute_code":"...
1
vote
0
answers
61
views
Change Custom status(Ready to ship) using rest api in magento2.1.12
I will create one custom order-status (Ready to Ship) in Magento-2.1.12.How to change this status using rest API in magento.2.1.12?Please suggest me.Thanks in advance.
1
vote
1
answer
697
views
unable to set store ID in place order REST API - Magento2
There is no option to set store ID in place order API:
rest/default/V1/carts/1/order
Payload has below data only:
{
"paymentMethod": {
"method": "banktransfer"
},
"...
2
votes
1
answer
4k
views
magento 2 Rest APi How to use default methods
Magento 2 Rest API have many default methods. I want to use those method and display data.
For that i have create one new user and assigned full admin access.
Trying to get the product information ...
0
votes
1
answer
191
views
Magento 2 add an attribute to product using rest
I want to add an attribute to a product using rest api. I have created the attribute but not added to the product.
How can i add it to respective product using rest api?
0
votes
0
answers
50
views
How to get Orders using Customer Token?
I want to access orders using customer token in rest API of Magento. Is it possible?
0
votes
1
answer
344
views
Magento 2 Rest auth for different website ids
I'm getting customer auth token with following REST request
http://mage.local/rest/default/V1/integration/customer/token
It is working fine for customers with website_id = 1, but not works for ...
0
votes
0
answers
83
views
rest/V1/order?serachCriteria API is not work in magento2.1.12
Suppose i will delete some products from Magento-2.After that my
http://HOSTNAME/rest/V1/orders?searchCriteria api is not work and giving error "Requested product doesn't exist".Anybody tell me.
0
votes
1
answer
3k
views
How to get qty of a product using rest api
I want to get product info including the product qty how can i achieve it.
Currently i am using
rest/default/V1/products?searchCriteria
To get all the product but it is missing qty attribute in it....
1
vote
1
answer
903
views
why after lock_expire_time customer account is not unlocked in magento2.1.12?
When a customer entered incorrect email and password 6 times, customer account is locked.That time api is showing error Unauthorized access. After lock_expire_time customer account is not unlocked, ...
2
votes
1
answer
1k
views
Get all simple product with REST API
I want to fetch all the simple product. The result should not include any configurable products.
Currently i am fetching using this http://host/rest/default/V1/products?searchCriteria
0
votes
2
answers
1k
views
Magento 2 - Class int[] does not exist
Scratching my head with this issue, and I just do not understand why this is happening in the first place. Made a custom REST API call to remove multiple items from the cart with one single API call ...
1
vote
0
answers
353
views
Magento2 REST API token validity
As magento2, provides rest service to generate token for customer
rest/V1/integration/customer/token
Token expiration is provided from here
We are planning to use headless magento approach, with ...
0
votes
2
answers
70
views
Getting Order of Particular Customer
How to get customer orders on the base of customer token in magento 2?Please help me.Thanks in Advance
3
votes
0
answers
999
views
M2.1.x REST API - Invalid type for value array. Expected type: string
Having some conflicts with a REST API I created. Trying to pass an array of strings; for example, "skus", but I get this error:
Invalid type for value: array. Expected type: string.
{vendor}/{module}...
1
vote
1
answer
49
views
Issues Regarding Rest Api
I made a website in Angular, Node.JS. But backend is using Magento 2.1.12. How to make a secure website by calling admin token, customer token generated. This Angular frontend call rest API for ...
0
votes
3
answers
1k
views
You did not sign in correctly or your account is temporarily disabled. In Magento 2 Admin panel Token
I am getting this error
"You did not sign in correctly or your account is temporarily
disabled"
during generating admin token in magento 2.1.12.
But admin panel is login with same username and ...
2
votes
3
answers
289
views
could not found detail of the product using REST API
I tried to get all the product using REST API,i used this url
"http://localhost/magento2.1/rest/V1/products/?searchCriteria[pageSize]=100&searchCriteria[currentPage]=1"
Output of this url:
"...
2
votes
2
answers
6k
views
401 Unauthorized for accessing customer api
I was able to get the admin token using the below url against the created admin user
http://username:[email protected]/index.php/rest/V1/integration/admin/token
The username and password is for ...
2
votes
1
answer
1k
views
What is the usage of itemId inside Update inventory REST API?
According to the swagger, the REST API PUT /V1/products/{productSku}/stockItems/{itemId} is used to update the product inventory.
However, for the attribute value itemId, I found no differences no ...
0
votes
0
answers
643
views
Response of rest api in magento 2.1.12 is too slow
Response of rest API in Magento 2.1.12 is too slow.
It take 15 to 20sec for load the data in website. I'm using default mode.
Anybody help me to how to increase speed of website?
2
votes
1
answer
857
views
Review Api for magento 2.1.12
I have successfully install this module Reviews/Rating
I call this url="/V1/review/mine/post" method="POST".I don't know what data is passed in body of this URL.
1
vote
0
answers
68
views
API Error - Token is not the correct length
We have two Magento 2.1 stores, one store i can connect to the REST API fine the other i get "Token is not the correct length" which is being classed as a 400 error in Postman.
The API has been ...
1
vote
1
answer
833
views
Talk to Magento 2 REST API using Order Increment ID
Is it possible to use the Order Increment on REST Endpoints in Magento 2 or do I have to call
https://example.com/rest/storeview/V1/orders?searchCriteria%5BfilterGroups%5D%5B0%5D%5Bfilters%5D%5B0%5D%...