<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: SHRINIVAS NEMAGOUDAR</title>
    <description>The latest articles on DEV Community by SHRINIVAS NEMAGOUDAR (@shrinivas-sn).</description>
    <link>https://dev.to/shrinivas-sn</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F4065777%2F1a1d6d18-903a-4697-ac6a-15d426602ccf.jpg</url>
      <title>DEV Community: SHRINIVAS NEMAGOUDAR</title>
      <link>https://dev.to/shrinivas-sn</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/shrinivas-sn"/>
    <language>en</language>
    <item>
      <title>Agmarknet API Alternative: A Free, Keyless Way to Get Mandi Prices in India</title>
      <dc:creator>SHRINIVAS NEMAGOUDAR</dc:creator>
      <pubDate>Thu, 06 Aug 2026 11:30:02 +0000</pubDate>
      <link>https://dev.to/shrinivas-sn/agmarknet-api-alternative-a-free-keyless-way-to-get-mandi-prices-in-india-38pg</link>
      <guid>https://dev.to/shrinivas-sn/agmarknet-api-alternative-a-free-keyless-way-to-get-mandi-prices-in-india-38pg</guid>
      <description>&lt;p&gt;If you've tried to pull daily mandi (wholesale market) prices programmatically from India's official sources — &lt;a href="https://agmarknet.gov.in" rel="noopener noreferrer"&gt;Agmarknet&lt;/a&gt; or the &lt;a href="https://www.data.gov.in/catalog/current-daily-price-various-commodities-various-markets-mandi" rel="noopener noreferrer"&gt;data.gov.in Open Government Data (OGD) platform&lt;/a&gt; — you've likely run into the same friction every developer in this space hits.&lt;/p&gt;

&lt;h2&gt;
  
  
  The friction with the official sources
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;A registration key is required.&lt;/strong&gt; data.gov.in's OGD API needs a free account and an API key before you can make a single request — an extra step for a quick prototype or hackathon project.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Inconsistent field names.&lt;/strong&gt; Response schemas vary across resources and have changed over time, which is why community wrapper packages exist just to normalize them.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Pagination quirks.&lt;/strong&gt; Large date ranges or state-wide pulls require manually paging through results rather than a single clean response.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;No built-in trend/history endpoint.&lt;/strong&gt; Getting a price history for a specific commodity means stitching together multiple daily pulls yourself.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;None of this is a knock on Agmarknet — it's the authoritative national source, covering over 3,000 regulated markets across India, and nothing else comes close to that scope. But if you specifically need &lt;em&gt;Maharashtra, Uttar Pradesh, Punjab, Madhya Pradesh, or Karnataka&lt;/em&gt; and want something you can hit from a terminal in under a minute, there's a lighter option.&lt;/p&gt;

&lt;h2&gt;
  
  
  A keyless alternative for 5 states
&lt;/h2&gt;

&lt;p&gt;&lt;a href="https://mandi-api.vercel.app" rel="noopener noreferrer"&gt;Mandi Price API&lt;/a&gt; wraps the same underlying government data for these five states into a free REST API with no signup, no API key, and normalized JSON — sourced daily from data.gov.in and re-synced every day at 8:30 PM IST.&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;curl &lt;span class="nt"&gt;-X&lt;/span&gt; GET &lt;span class="s2"&gt;"https://mandi-api.onrender.com/v1/prices?state=Maharashtra&amp;amp;commodity=Onion"&lt;/span&gt; &lt;span class="se"&gt;\&lt;/span&gt;
  &lt;span class="nt"&gt;-H&lt;/span&gt; &lt;span class="s2"&gt;"Accept: application/json"&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;That's the entire integration — one HTTP request, JSON back, no auth header.&lt;/p&gt;

&lt;h2&gt;
  
  
  What's covered
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;code&gt;GET /v1/states&lt;/code&gt; — list of supported states&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;GET /v1/commodities&lt;/code&gt; — list of tracked crops, optionally filtered by state&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;GET /v1/markets&lt;/code&gt; — mandi/market list per state&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;GET /v1/prices&lt;/code&gt; — current wholesale prices by state, market, and commodity&lt;/li&gt;
&lt;li&gt;
&lt;code&gt;GET /v1/prices/history&lt;/code&gt; — historical price trend data for charting&lt;/li&gt;
&lt;/ul&gt;

&lt;h2&gt;
  
  
  When to use which
&lt;/h2&gt;

&lt;p&gt;If you need nationwide coverage or commodities outside the 5 supported states, Agmarknet/data.gov.in directly is still the right call. If your use case is scoped to Maharashtra, UP, Punjab, MP, or Karnataka and you want to skip the registration step, Mandi Price API is built exactly for that.&lt;/p&gt;

&lt;p&gt;Full endpoint reference is in the &lt;a href="https://mandi-api.vercel.app/docs" rel="noopener noreferrer"&gt;docs&lt;/a&gt;, or try live requests in the &lt;a href="https://mandi-api.vercel.app/playground" rel="noopener noreferrer"&gt;interactive playground&lt;/a&gt; before writing any code.&lt;/p&gt;




&lt;p&gt;&lt;em&gt;Mandi Price API is free and open, licensed under CC BY-NC-SA 4.0. &lt;a href="https://github.com/shrinivas-sn/mandi-api" rel="noopener noreferrer"&gt;Source on GitHub&lt;/a&gt;.&lt;/em&gt;&lt;/p&gt;

</description>
      <category>api</category>
      <category>agriculture</category>
      <category>opensource</category>
      <category>webdev</category>
    </item>
  </channel>
</rss>
