<?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: Oliver Monte</title>
    <description>The latest articles on DEV Community by Oliver Monte (@oliverpaulamontestar).</description>
    <link>https://dev.to/oliverpaulamontestar</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%2F4167512%2F5d8806c9-9430-4e5a-a81d-2a3d1c409ec2.png</url>
      <title>DEV Community: Oliver Monte</title>
      <link>https://dev.to/oliverpaulamontestar</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/oliverpaulamontestar"/>
    <language>en</language>
    <item>
      <title>What finally fixed my Instagram profile lookups — a pay-per-request API instead of my own scrapers</title>
      <dc:creator>Oliver Monte</dc:creator>
      <pubDate>Thu, 08 Oct 2026 02:06:10 +0000</pubDate>
      <link>https://dev.to/oliverpaulamontestar/what-finally-fixed-my-instagram-profile-lookups-a-pay-per-request-api-instead-of-my-own-scrapers-4fc2</link>
      <guid>https://dev.to/oliverpaulamontestar/what-finally-fixed-my-instagram-profile-lookups-a-pay-per-request-api-instead-of-my-own-scrapers-4fc2</guid>
      <description>&lt;p&gt;For about a year I've been building a small lead-facing tool that shows a snapshot of a public Instagram profile — name, profile photo, follower and post counts, whether the account is private. Nothing exotic. The hard part was never the UI. It was &lt;em&gt;getting the data reliably.&lt;/em&gt;&lt;/p&gt;

&lt;p&gt;I started the way everyone does: &lt;code&gt;instagrapi&lt;/code&gt; + a couple of aged accounts + residential proxies. It worked on my machine for about two weeks at a time. Then a checkpoint would pop, a session would die, or Instagram would change a payload and half my fields came back empty. I was spending more time babysitting login sessions than building the actual product.&lt;/p&gt;

&lt;p&gt;What I actually needed was boring: give it a username, get clean JSON back, don't make me think about accounts or proxies. I moved the lookups to &lt;a href="https://hikerapi.com" rel="noopener noreferrer"&gt;hikerapi.com&lt;/a&gt; — a hosted endpoint where one GET with a key in the header returns the profile as JSON. The part I care about: no login session to keep alive, and the fields come back consistently enough that I normalize them once and move on. Pay-per-request also means I can reason about cost per lookup instead of amortizing a pile of proxy and account spend.&lt;/p&gt;

&lt;p&gt;Tradeoffs / what didn't totally work: it's per-request, so for big bulk pulls the cost adds up and you'll want aggressive caching (I cache each profile for a few hours). It's also a third-party dependency, so you still have to handle empty responses for deleted or odd accounts gracefully. Compared to rolling my own with instagrapi, I traded "free but fragile and high-maintenance" for "costs money but predictable." For a product that needs to not break on a random Tuesday, that was the right trade. If you're doing a one-off research scrape, honestly your own instagrapi script is probably fine.&lt;/p&gt;

&lt;p&gt;If I were starting over I'd put the caching layer in from day one instead of bolting it on after the first surprise bill.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;I'm part of HikerAPI's user-rewards program — they credit my account for posts like this. Sharing my actual experience.&lt;/p&gt;
&lt;/blockquote&gt;

</description>
      <category>python</category>
      <category>api</category>
      <category>webdev</category>
      <category>instagram</category>
    </item>
    <item>
      <title>I replaced my flaky instagrapi setup with a pay-per-request Instagram API</title>
      <dc:creator>Oliver Monte</dc:creator>
      <pubDate>Wed, 07 Oct 2026 00:30:47 +0000</pubDate>
      <link>https://dev.to/oliverpaulamontestar/i-replaced-my-flaky-instagrapi-setpythonwebdevapiproductivityup-with-a-pay-per-request-instagram-api-4dig</link>
      <guid>https://dev.to/oliverpaulamontestar/i-replaced-my-flaky-instagrapi-setpythonwebdevapiproductivityup-with-a-pay-per-request-instagram-api-4dig</guid>
      <description>&lt;p&gt;The question I was trying to answer was dumb and simple: who follows this Instagram account, and what's their profile pic? I was doing it for a small store I help run that keeps an eye on its mentions and tagged posts.&lt;/p&gt;

&lt;p&gt;I started where everyone starts: instagrapi. It works until it doesn't. Logins get challenged, sessions die, a scrape that ran fine on Monday throws on Thursday, and I was spending more time babysitting the login than using the data. I didn't want to run a headless browser farm for what is basically a few reads a day.&lt;/p&gt;

&lt;p&gt;I was skeptical of the "just use an API" answer, because most of them are dead, sketchy, or want a $300/month minimum. Then I tried HikerAPI (&lt;a href="https://hikerapi.com" rel="noopener noreferrer"&gt;hikerapi.com&lt;/a&gt;) — plain REST, you send an &lt;code&gt;x-access-key&lt;/code&gt; header, and you pay per request (starts around $0.001/req, 100 free to start). No session to keep alive, no login challenge, no proxy rotation on my side.&lt;/p&gt;

&lt;p&gt;The one thing it actually solved for me: pulling a profile plus its followers without the whole thing falling over. Rough version of what I run:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="kn"&gt;import&lt;/span&gt; &lt;span class="n"&gt;requests&lt;/span&gt;

&lt;span class="n"&gt;headers&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;x-access-key&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;YOUR_KEY&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;}&lt;/span&gt;

&lt;span class="n"&gt;user&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;requests&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;https://api.hikerapi.com/v2/user/by/username?username=natgeo&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;headers&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;).&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;()&lt;/span&gt;

&lt;span class="n"&gt;resp&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;requests&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;get&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;
    &lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;https://api.hikerapi.com/v2/user/followers&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
    &lt;span class="n"&gt;params&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="p"&gt;{&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;user_id&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt; &lt;span class="n"&gt;user&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="s"&gt;pk&lt;/span&gt;&lt;span class="sh"&gt;"&lt;/span&gt;&lt;span class="p"&gt;]},&lt;/span&gt;
    &lt;span class="n"&gt;headers&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="n"&gt;headers&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt;
&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="nf"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;resp&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;json&lt;/span&gt;&lt;span class="p"&gt;())&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;Honest tradeoffs, because it isn't magic:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Vs raw scraping / instagrapi: you give up control and you pay per call. If you're pulling millions of rows, per-request pricing adds up fast and a self-hosted scraper is cheaper. For low-to-medium volume where uptime matters more than unit cost, I'll pay the $0.001 to not get paged at 2am.&lt;/li&gt;
&lt;li&gt;You're trusting a third party for freshness and coverage, so I still sanity-check fields before I rely on them.&lt;/li&gt;
&lt;li&gt;It's reads, not a full account automation tool. If you need to act as an account, this isn't that.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;For my use case (a handful of profile/follower reads a day, has to just work) it was the right call. For a big batch job I'd still roll my own.&lt;/p&gt;

&lt;p&gt;Curious what everyone else lands on: at what request volume does pay-per-request stop making sense for you, and you go back to self-hosting?&lt;/p&gt;

</description>
      <category>python</category>
      <category>webdev</category>
      <category>api</category>
      <category>productivity</category>
    </item>
  </channel>
</rss>
