OHLC.dev editorialIDX

IDX Smart Money Trading Analyzer Using Insider Activity and Fundamental Intelligence

This article presents an IDX Smart Money Trading Analyzer using IDX API data to evaluate insider activity fundamental intelligence and composite trading scores for stock screening.

September 11, 20265 min readRafatar
IDX Smart Money Trading Analyzer Using Insider Activity and Fundamental Intelligence

Stock market screening requires a combination of market behavior analysis and fundamental evaluation to identify potential investment opportunities. Price movement alone does not fully represent stock quality because investor confidence can also be influenced by insider transactions, company fundamentals, valuation conditions, and financial risk indicators.

This project develops an IDX Smart Money Trading Analyzer using Indonesia Stock Exchange API data. The system integrates insider transaction screening and fundamental metric analysis to generate a structured stock evaluation framework.

The main objective of this system is to transform raw IDX API data into an analytical dashboard that provides insights regarding:

  • Insider transaction activity

  • Potential accumulation and distribution signals

  • Fundamental metric availability

  • Composite trading score

  • Screening interpretation

The system is implemented using Python with API integration, Pandas for data processing, NumPy for numerical calculation, and automated scoring logic. The final output provides a simplified trader-oriented report for early-stage stock screening.


The first stage initializes the required Python libraries and configures the IDX API connection. The system defines the API endpoint, authentication headers, and a reusable API request function to retrieve market information.

Cell 1 — Import Library and API Configuration

import requests
import pandas as pd
import numpy as np
from IPython.display import display


API_KEY = "YOUR_API_KEY"


BASE_URL = (
    "https://indonesia-stock-exchange-idx.p.rapidapi.com"
)


HEADERS = {

    "Content-Type":
    "application/json",

    "x-rapidapi-host":
    "indonesia-stock-exchange-idx.p.rapidapi.com",

    "x-rapidapi-key":
    API_KEY

}


def idx_api(endpoint, params):

    url = BASE_URL + endpoint

    r = requests.get(
        url,
        headers=HEADERS,
        params=params
    )

    print(endpoint)
    print("Status:", r.status_code)

    return r.json()


print("""
==================================================
 IDX SMART MONEY & FUNDAMENTAL ANALYZER
==================================================
""")

This cell prepares the API environment and creates a universal request function that is used by the following analysis modules.


The second stage retrieves insider transaction screening data from IDX API. The system collects insider movement information based on period, action type, ownership threshold, and transaction source. The response is normalized into a structured DataFrame for further interpretation.

Cell 2 — Insider Transaction Screening

insider = idx_api(

"/api/analysis/insider-screening",

{

"source_type":
"SOURCE_TYPE_UNSPECIFIED",

"period":
"2025-12",

"page":
1,

"min_percentage":
0,

"limit":
100,

"action_type":
"ACTION_TYPE_UNSPECIFIED",

"symbols":
"",

"min_ownership":
0

}

)


insider_df = pd.json_normalize(

    insider.get(
        "data",
        insider
    )

)


display(insider_df)


print(
"Total Movement:",
insider_df["summary.totalMovements"].iloc[0]
)

This module identifies insider activity and provides initial information regarding internal buying or selling behavior.


The third stage develops the smart money signal engine. The system evaluates insider transaction movement by comparing buy and sell activity. Based on the result, the system generates an insider signal classification:

  • No insider activity

  • Accumulation

  • Distribution

  • Balanced activity

Each classification receives a predefined score that contributes to the final trading evaluation.

Cell 3 — Smart Money Signal Engine

summary = insider_df.iloc[0]


total_move = summary.get(
    "summary.totalMovements",
    0
)


buy_move = summary.get(
    "summary.totalBuyMovements",
    0
)


sell_move = summary.get(
    "summary.totalSellMovements",
    0
)



if total_move == 0:

    insider_signal = "NO INSIDER ACTIVITY"

    insider_score = 50


elif buy_move > sell_move:

    insider_signal = "ACCUMULATION"

    insider_score = 80


elif sell_move > buy_move:

    insider_signal = "DISTRIBUTION"

    insider_score = 30


else:

    insider_signal = "BALANCED"

    insider_score = 50



print("INSIDER SIGNAL :", insider_signal)

print("INSIDER SCORE  :", insider_score)

This cell converts insider transaction data into a simplified smart money indicator that represents potential internal confidence or selling pressure.


The fourth stage performs fundamental intelligence analysis. The system retrieves fundamental metrics from IDX API and classifies each metric into several categories:

  • Profitability

  • Valuation

  • Risk

  • Other

This classification provides an overview of available fundamental information that can support stock evaluation.

Cell 4 — Fundamental Metric Scanner

fundamental = idx_api(

"/api/emiten/fundachart/metrics",

{

"metric_name":
"fundachart"

}

)



fund_df = pd.json_normalize(

fundamental.get(
    "data",
    fundamental
)

)



def classify_metric(x):

    x = str(x).lower()


    if any(
        k in x for k in
        [
        "roe",
        "roa",
        "profit",
        "margin",
        "earning"
        ]
    ):

        return "PROFITABILITY"



    elif any(
        k in x for k in
        [
        "pe",
        "pb",
        "valuation"
        ]
    ):

        return "VALUATION"



    elif any(
        k in x for k in
        [
        "debt",
        "leverage",
        "liability"
        ]
    ):

        return "RISK"



    else:

        return "OTHER"

This module provides fundamental coverage by organizing financial indicators into meaningful analytical categories.


The final stage creates the trader intelligence dashboard. The system combines insider score and fundamental score into a composite trading score using weighted calculation.

The final score uses:

  • Insider activity score with 30% weight

  • Fundamental score with 70% weight

The result is interpreted into three categories:

  • Strong Screening Result

  • Watchlist

  • Low Conviction

Cell 5 — Final Trader Intelligence Dashboard

fund_metric_count = len(fund_df)


if fund_metric_count > 0:

    fundamental_score = min(
        100,
        fund_metric_count * 5
    )

else:

    fundamental_score = 0



final_score = (

    insider_score * 0.3

    +

    fundamental_score * 0.7

)



print(
"TOTAL SCORE :",
round(final_score,2),
"/100"
)



if final_score >= 75:

    print(
"""
🟢 STRONG SCREENING RESULT

Kandidat untuk analisa lanjutan:
- cek trend harga
- cek volume breakout
- cek support resistance
"""
)



elif final_score >=50:

    print(
"""
🟡 WATCHLIST

Belum cukup kuat.
Tunggu konfirmasi:
- volume
- price action
- market trend
"""
)



else:

    print(
"""
🔴 LOW CONVICTION

Belum memenuhi kriteria screening.
"""
)

This dashboard provides a final interpretation by combining insider behavior and fundamental availability into one screening score.

result

Conclusion

This project successfully developed an IDX Smart Money Trading Analyzer using IDX API integration to evaluate stock conditions through insider activity and fundamental intelligence analysis.

The system analyzes insider transaction behavior to identify potential accumulation, distribution, or neutral conditions. In addition, the fundamental scanner evaluates available financial metrics by classifying indicators into profitability, valuation, and risk categories.

The final dashboard combines these components into a composite trading score that provides a simplified screening interpretation. This approach allows investors to evaluate stocks using multiple dimensions rather than relying on a single indicator.

However, this system is designed as an initial screening tool and not as a direct buy or sell recommendation. Further analysis involving price trend, trading volume, valuation, financial statements, and market conditions is required before making investment decisions.

Overall, the IDX Smart Money Trading Analyzer demonstrates how API-based financial data processing can support automated stock screening and provide structured insights for data-driven investment research.