How to Use Flipkart API to Fetch Products with PHP

For affiliate marketers, coupon websites and comparison websites, Flipkart offers its API. With its API, one can get products, prices, deals and even orders done by one’s affiliate. Most of the companies still rely on crawling or using but use of API is not recommended for better management. If you are one of those who want to get products from Flipkart by using its API, you must know how to use curl. Because I will be using CURL in this code.

For using the API, you must first have affiliate account. If you are reading this post, It means you already have one. I also recommend you to check the Affiliate management program by Techlomedia Gadgets. Basically this program is for those who are related to smartphones affiliate. But you can contact for more custom banners.

Now come to the Flipkart API.

You can get the products feed by using this URL:

If you prefer XML, you can use this URL

Here, add your tracking id of Flipkart where it asks.

This URL will give you the URLs of different flipkart categories. If you want to fetch data from all categories, you can get it. You can also just use it for specific data.

Just parse this JSON to get URLs. For these categories specific URLs, we need authentication. You will be provided the authentication credentials in your Flipkart affiliate section.

This code will give only 50 products of that specific category. You will also get the URL to the next 50 products in each iteration until there is no product left. You can access next URL with this line:

I didn’t want to share my credential or affiliate tracking in code. This is why, you will have to test the code with your own affilaite tracking and credentials.

If you have any confusion, you can ask in comments.

Subscribe To Our Newsletter

Subscribe To Our Newsletter

Join our mailing list to receive the latest updates, web design resources and tools.

You have Successfully Subscribed!

About The Author

    ADD YOUR COMMENT

Subscribe To Our Newsletter

Subscribe To Our Newsletter

Receive fresh web design resources and SEO tips in your email by our weekly newsletter

You have Successfully Subscribed!

Pin It on Pinterest

Share This

Share This

Share this post with your friends!