jsonscraper

How to Build Daily IG Creator Monitoring with Python

A pipeline for marketers and analysts: retrieve public profile data, save snapshots, and detect changes without manually checking accounts.

Editorial Policy Report an error

Marketing teams often have to check dozens of accounts manually to understand which potential creators are active, how their audiences are changing, and when a profile was last updated. A one-off spreadsheet quickly becomes outdated: follower counts and profile descriptions change, while post dates and individual post metrics have to be gathered again.

Article: How to Build Daily IG Creator Monitoring with Python
Summary: Learn how to automate daily monitoring of public IG profiles with the IG Scraper API: request profile data, store observation history, and generate a change report.
Image role: cover — the central idea
Section: 
Visual subject: A data pipeline dashboard concept showing a neatly organized grid of public social media profile cards feeding timestamped JSON records into a simple analytics c
© jsonscraper · AI-generated illustration

A practical solution is to keep a small observation log: once a day, request public profiles from a predefined list, save each response with its collection time, and compare new values with previous snapshots. This approach helps identify accounts for further manual review, assess activity, and prepare regular reports. It does not replace analytics available to the account owner: for example, public profile information does not provide access to internal reach metrics.

First, decide what you need to track

For finding potential partners, a short list of fields is usually enough: username, profile ID, verification status, follower count, post count, bio, and collection time. These values make it possible to spot profile changes and compare accounts in a chosen niche. The actual fields depend on the API response; check the current JSON in the documentation before processing it, and do not rely on fields that are not present.

To track content activity, you can add post data to the profiles. The IG Scraper API map lists separate routes for user media and reels, as well as requests for media and comments. Add these as a separate step after checking the profile: first confirm the required parameters and response structure in Postman, then record only the fields your report actually needs.

A useful monitoring rule is to store raw responses separately from normalized rows. Raw JSON lets you recheck your interpretation if the API response changes; a normalized table is convenient for charts and filters. In both cases, save the request time so you can distinguish current values from historical ones.

Connect the IG Scraper API

jsonscraper’s base URL for the IG API is https://ig.jsonscraper.com. The official documentation shows a profile request by username: GET /v1/user/by/username with the parameters username, license_key, and cache_timeout. For example, the documentation shows a URL like https://ig.jsonscraper.com/v1/user/by/username?username=apple&license_key=YOUR_LICENSE_KEY&cache_timeout=60 for a test account. Use the cache parameter only as allowed for the specific route and in a way that fits your task: polling frequency should match how quickly you need updates.

To check the response structure, open the IG Scraper API page and follow the link to its Postman collection. In the example, a successful response contains a status, an ig object with the profile ID, username, and verification status, as well as a timestamp. The documentation separately lists route groups for users, media, search, hashtags, and locations, allowing you to expand data collection as your analytics needs become clearer.

Store your API key in an environment variable, not in source code or a client application. jsonscraper’s documentation recommends keeping the key in the environment and not embedding it in client builds. Limit access to the key in your workflow; for example, make it available only to the background collection task.

A minimal working example in Python

The script below reads usernames from an environment variable, requests each profile, and writes a JSONL file. JSONL is convenient for an initial prototype: one line represents one snapshot. The code deliberately saves the entire response object rather than assuming all profile fields will always be present. After the first run, inspect the actual response before creating a stable table schema.

import json
import os
import time
from datetime import datetime, timezone
from pathlib import Path
from urllib.parse import urlencode
from urllib.request import Request, urlopen

API_KEY = os.environ["JSONSCRAPER_LICENSE_KEY"]
USERNAMES = [name.strip() for name in os.environ["IG_USERNAMES"].split(",") if name.strip()]
BASE_URL = "https://ig.jsonscraper.com/v1/user/by/username"
OUTPUT = Path("instagram_profiles.jsonl")


def fetch_profile(username: str) -> dict:
    query = urlencode({
        "username": username,
        "license_key": API_KEY,
        "cache_timeout": 60,
    })
    request = Request(f"{BASE_URL}?{query}", headers={"Accept": "application/json"})
    with urlopen(request, timeout=30) as response:
        return json.load(response)


with OUTPUT.open("a", encoding="utf-8") as output:
    for username in USERNAMES:
        collected_at = datetime.now(timezone.utc).isoformat()
        try:
            payload = fetch_profile(username)
            row = {
                "collected_at": collected_at,
                "requested_username": username,
                "ok": True,
                "payload": payload,
            }
        except Exception as exc:
            row = {
                "collected_at": collected_at,
                "requested_username": username,
                "ok": False,
                "error": str(exc),
            }

        output.write(json.dumps(row, ensure_ascii=False) + "\n")
        output.flush()
        time.sleep(1)

Before running the script, set the configuration in your environment:

export JSONSCRAPER_LICENSE_KEY="your_key"
export IG_USERNAMES="creator_one,creator_two,creator_three"
python monitor.py

The delay in the example allows the list to be processed more gradually; it is not a stated API limit. For a production schedule, configure polling frequency and error handling according to your plan, the documentation, and your freshness requirements. If a request fails, the saved record helps you identify the problem instead of silently skipping the account.

Normalize data after checking the response

After inspecting the response for the route you use, identify a stable set of columns. For example, an observation table might include collection time, username, profile ID, verified response status, and the required counters—if they are present in the JSON. Define explicitly what to do when a field is missing: save an empty value, mark the record as incomplete, or flag it for another review.

Do not overwrite yesterday’s row with today’s value. Snapshot history is needed to calculate differences between dates and spot changes. For follower counts, calculate the difference between consecutive successful observations of the same profile; matching by a stable ID is preferable to matching only by username, which can change.

Consider storing raw responses for a limited period if they contain more data than the report needs. The normalized table should include only fields justified by the specific task. For public creator research, this usually reduces the amount of data and makes it easier to explain why the information is being collected.

Schedule a daily run and notification

On a server, you can run the script with a task scheduler such as cron; in an automation platform, you can run it on a schedule and make HTTP requests. The basic sequence consists of a trigger, reading the profile list, calling the route for each profile, checking for a successful response, writing a row to storage, and preparing a summary. In n8n or Make, it is convenient to split the same steps into separate nodes so that one profile’s failure does not stop the entire batch.

For the report, calculate simple metrics: how many profiles were processed successfully, which ones changed their follower count relative to the previous successful snapshot, and when each record was last updated. A separate error list makes it easier to identify incorrect usernames, unavailable profiles, and temporary request problems. If you add posts, first decide on the required history depth and fields, then connect the corresponding route from the documentation.

Configure caching thoughtfully, too. The documentation describes cache_timeout as a parameter for supported routes that allows recent results to be reused. For a daily comparison report, choose a setting that matches the required data freshness; do not mix a cached response with a new checkpoint without noting that in the log.

What this monitoring can show

Once snapshots have accumulated, your team will have a verifiable history of observations for selected public profiles. You can compare metric changes, find records that have not been updated for a long time, and create a shortlist of accounts for manual assessment. If media collection is available for the route and task you have chosen, you can add posts to profiles and analyze posting frequency or content formats—provided the specific fields are confirmed in the documentation.

Use metrics as a filter for research, not as an automated decision about a partnership. Follower count alone does not describe how well an audience fits a brand, the quality of the content, or a creator’s commercial suitability. Add a human review of the profile and keep selection criteria separate from technical data collection.

For a trial run, open the IG API collection in Postman, set up your key, and make a profile request. Then transfer the verified parameters to your script or automation. This gives you reproducible daily collection, a history of changes, and a foundation for an analytics report—without starting with a custom page scraper.

People

No people listed for this article yet.

Keep readingHow to Track Competitors’ IG Content Over Time: An API Pipeline in Python
Read the next article

Turn what you read into a working integration

Explore jsonscraper's social-data APIs, test requests and build your next workflow.

Explore APIs