Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
0 votes
1 answer
112 views

Magento 2.3 Disallow Post to /V1/Customers

I am battling spam accounts being generated via Magento's REST API for customers. Someone keeps hitting my site with Postman and dumping in hundreds of fake accounts. I have set Allow Anonymous Guest ...
0 votes
1 answer
277 views

Get list of orders with increment_id

I can use the Magento API (https://magento.redoc.ly/2.4.4-admin/tag/ordersid) to get a list of orders using the following endpoint: "rest/V1/orders/items". However, this endpoint does not ...
4 votes
3 answers
9k views

Magento 2 searchCriteria using REST APIs

I have the following query: $url = http://kostakfashion.com/rest/V1/products/?searchCriteria[filter_groups][0][filters][0][field]=category_gear&searchCriteria[filter_groups][0][filters][0][...
0 votes
0 answers
382 views

Magento 2: How To Create Product Progamatically Using Custom Rest API

I need to create a product using a custom Rest API. (this is my first time working on API). So to check API whether it's working or not I wrote the code below, API is working, now I need to give ...
0 votes
1 answer
33 views

How to connect two magento2 application

I have two magento2 application running which are M2(a) and M2(b), I want all product on M2(a) to be displaying on M2(b) automatically, I have created an Integration on M2(a) by going to admin->...
0 votes
2 answers
6k views

Magento2 Shipping Methods rest api

Is There any possibility to fetch all shipping methods using rest api in magento2 Thanks
2 votes
0 answers
476 views

Magento 2, How to get and set of custom_attributes value for Rest API

API: /rest/V1/products?fields=items,total_count,search_criteria[page_size,current_page]&searchCriteria[filterGroups][0][filters][0][field]=category_id&searchCriteria[filterGroups][0][filters][...
0 votes
1 answer
2k views

Get order by date and status filters in magento 2 with rest api

Get Orders details using rest API with filters status and date range in magneto 2.4
0 votes
1 answer
431 views

Magento Custom API Product Attribute Not Saving

I have created a custom API to update 4 attributes of the product out of which only 2 are updating not others. I have already created attributes and assigned them to a product and working properly ...
1 vote
1 answer
639 views

Any examples on how to use requisition_lists API Endpoint?

ORIGINAL POST Trying to use the save requisition list REST API endpoint. The API docs are not very clear on what the values should be and currently don't have access to the B2B module code to see ...
0 votes
0 answers
177 views

Extend API V1/products to put the not available products at the end

I want to display out of stock products at the end of the V1/products response. So far I tried to create a plugin on Magento\Catalog\Api\ProductRepositoryInterface to override the getList method but ...
4 votes
3 answers
9k views

Magento 1 - How to set HTTP Response Code in Custom REST API

Hi Guys for a project i try to extend the Magento REST API. I have some problems with my error handling. I don't know how to send the right Http Response Code. I tried it with something like this: ...
5 votes
2 answers
5k views

Magento 2 Customer login and forgot Password using Rest API

I need customer login and customer forgot password using Magento 2 API. Can you please help me. I was search but not getting any code from google.
0 votes
1 answer
263 views

How to add new fields to M2.4.2 CMS REST API response?

How would I go about adding new custom fields I have created for CMS pages to M2.4.2 CMS REST API responses (and possibly even search/filtering)? For example, if I want to add new fields to retrieving ...
4 votes
1 answer
3k views

Magento 2 call external REST api

I am trying to call external api from Magento. Below is the request, $client = $this->_httpClientFactory->create(); $client->setUri('thirdpartyurl.com/api/'); $client->setMethod(\...
5 votes
3 answers
6k views

Magento 2 requesting external REST API

I want to call a 3rd party REST API within Magento 2. Is there any class to handle the HTTP requests and responses for that?
3 votes
2 answers
2k views

How to call a 3rd party API from a controller? Magento 2

I built a custom module. Its admin tables with CRUD functionality. I am putting a new button on the grid via the Ui_component listing XML file. When this button gets clicked I want to call a 3rd party ...
8 votes
5 answers
61k views

Magento 2: How to get order information using REST API?

I want to get order,customer information by using REST API. Anyone have idea about this?
9 votes
2 answers
22k views

How to integrate magento REST API with third party?

I was just trying to find information about REST API. There are some examples at Magento resource and some private blogs. All are the same!! As basic info, I found if I want to update products through ...
0 votes
2 answers
57 views

Do a action before insert products by endpoint magento 2

I wanna make a verification before inserting products on my Magento 2.3 in the default endpoint. Here is a sample: I post a product on rest/default/V1/products endpoint, but I want to check if this ...
0 votes
1 answer
717 views

Magento2.3.4 different hours in REST API call GET Orders and the real order hour timezone

I have selected Timezone (Configuration->General->Locale Options) Central European Standard Time (Europe/Warsaw) Order 10004 has been created at: Sep 21, 2021, 5:59:34 PM When I send API ...
0 votes
0 answers
61 views

Magento 2 : How to Fetch Particular Product Category Name via API

I want to access specified product category information using API.
1 vote
1 answer
349 views

Magento 2 calling External API

How do I call an External API in Magento 2? And what file/folder do I do it in?
0 votes
1 answer
194 views

Magento API to use to integrate ERP System

An ERP company asks you for recommendations which Magento API to use to integrate a client It is expected that at times large amount of product and category changes will need to be pushed from the ERP ...
3 votes
0 answers
591 views

What is protect code used for?

We're working on a project where we're replacing our existing web store with a custom Magento integration. We need a way for a guest customer to retrieve information about their order by following a ...
0 votes
1 answer
49 views

Magento2 Order Number different in REST API orders

I've changed my order number to 2000. INSERT INTO magento.sequence_order_1 (sequence_value) VALUES ('2000'); Then change lenght of order number <?xml version="1.0"?> <config xmlns:...
0 votes
1 answer
680 views

Why my module API communication is blocked by my Magento 2.4?

My ERP module connects via API and sends 1k of the product's data when there are changes from my ERP side. In the logs, I just see the message below and my stock hasn't been updated. Web API is unable ...
8 votes
5 answers
10k views

How to add a new address (shipping or billing or another) via Magento 2 REST API?

There are API's available to fetch and delete address of a customer but not create a new one. GET /V1/customers/addresses/:addressId GET /V1/customers/me/billingAddress GET /V1/customers/:...
1 vote
3 answers
1k views

Magento 2.4.2 rest api issue with get current customer details using customer token

I am using latest magento version 2.4.2 I have created customer token using postman eg. https://<magento.host>/rest/V1/integration/customer/token sending in body { "username" : "...
6 votes
8 answers
24k views

Consumer is not authorized to access %resources Magento_Sales::sales

I have this basic API script: <?php ini_set('display_errors', 1); ini_set('display_startup_errors', 1); error_reporting(-1); $usr = [ 'username' => 'username', '...
0 votes
1 answer
947 views

retrieve the oauth access code in magento 1.9

$callbackUrl ="http://host/mgstore/customApi/test.php"; $temporaryCredentialsRequestUrl = "http://host/mgstore/oauth /initiate?oauth_callback=".urlencode($callbackUrl); $adminAuthorizationUrl = 'http:/...
0 votes
2 answers
2k views

How to not use attribute default value over rest API in magento2

Im working on api integration between one store of magento2 multi store installation and product db of a client. Our current problem is that part of the items for in our store are duplicated (same sku)...
0 votes
0 answers
193 views

How to implement Custom online shipping method with shipping API?

I have created one shipping module.I need to integrate flash express API's in that. How to integrate the APIs?
0 votes
0 answers
147 views

Can I use a PUT request when required fields aren't filled in?

I'm trying to run about 10,000 put requests to update pricing via the API. A lot of the products have fields that are required, but aren't filled in. Everything works when I update the pricing with a ...
2 votes
1 answer
3k views

Magento 2: Where are the Token-based authentication access token stored?

I have been following along with this guide: https://devdocs.magento.com/guides/v2.3/get-started/authentication/gs-authentication-token.html This guide shows how a token can be requested and shows ...
1 vote
1 answer
2k views

Overwrite magento 2 default customer rest api

I use magento 2 rest /V1/customers/me it get response like this { "id": 2, "group_id": 1, "default_billing": "2", "default_shipping": "2", "created_at": "2018-03-30 07:53:13", ...
1 vote
2 answers
1k views

Why Magento is not giving final price in rest api?

I have recently try to get product final price via rest api. You can check special_price is already active and it will 20 but of price are coming 45 it will be 20. API URL : http://magento.local/...
1 vote
0 answers
42 views

how i can retrieve Minimum Amount in magento 2 using REST API?

Dears I am using Magento ver. 2.2.7 as backend for my app, i want to get "Minimum Amount" for orders when my users review them bascket. So i am looking for API to retrieve value of "...
0 votes
1 answer
626 views

On Adding items in cart for guest user using Postman getting error

I have successfully run two REST API's but on running the third one http://127.0.0.1/mag/rest/V1/guest-carts/81/items { "cart_item": { "quoteId": 81, "sku": "...
4 votes
1 answer
5k views

Magento2: Add a New Customer Address

I'm trying to add a new customer address using Magento 2 REST API in C#. I'm using POST /V1/customers/:id. I keep getting the below error. Where do I find the regionId? Is there another API I can use ...
3 votes
1 answer
615 views

Custom REST API for fetch all product with stock information

I am creating custom rest API for getting all products including out of stock products too but I am not able to get out of stock products. /** * Get products with filter. * * @param string $...
0 votes
0 answers
126 views

Magento 2 How to get products details with qty calling products endpoint?

Magento 2 How to get products details with qty calling products endpoint? I need to get the qty from the products endpoint.
0 votes
0 answers
213 views

Magento 2 How to get Custom Attribute Value Of Order Using Rest API

I have created one attribute for order named "custom_fee" and it is showing okay in magento orders frontend as well as backend but when I tries to access order data with rest API , I am not ...
6 votes
5 answers
26k views

Magento 2: get product through api using id?

I want to get product information using API call. I have product id of that product is it possible to do that.
0 votes
1 answer
1k views

Will using async or bulk endpoints actually improve performance of import processes?

We have a multi-store setup with 16 stores and every store has it's own language, we have a lot of store-specific information. Most of our products are configurable products with lots of variants, so ...
3 votes
2 answers
2k views

Get pending orders for a specific customer using REST API Magento 2

I am trying to get the pending orders for a specific customer using : https://{domain.com}/index.php/rest/V1/orders?searchCriteria[filter_g‌​roups][0][filters][0‌​][field]=status&searchCriteria[...
0 votes
0 answers
331 views

Curl request doesn't login to my API, why?

I've been working on this code to log in to my API. But every time I try to login using CURL I get the following error {"message":"The request entity's media type 'multipart/form-data' ...
0 votes
1 answer
763 views

API -> add image with external url instead of base64

Is there any extension that give us the possibility to add external url instead of a base64 string when I adding/update product via magento 2 api?
1 vote
1 answer
2k views

How to reduce Magento 2 rest api performance time?

I have created some custom rest api's and using Magento's default rest api's. I want to reduce the loading time of the api, as I have custom api's too so the request time and response time is quite ...
2 votes
1 answer
4k views

Check products in cart if they are out of stock before place order REST API : Magento 2

I am building mobile application using Magento 2, I had an old defined cart which had a product and when checking out it gives an error saying the item is out of stock, that happened after payment and ...

1 2
3
4 5
12