Get started

    API Endpoint

        https://i-bursa.herokuapp.com/
                

i-Bursa API will provides programmatic access to read stock data for various stock from Bursa Malaysia Main Market and get future predictions either the stocks of the particular market will increase or decrease.

To use this API, you need an API key. Please contact us at HERE to get your own API key.

Get Stock Data


curl --location --request GET "https://i-bursa.herokuapp.com/getstocksdata?\
stocksname=MSNIAGA&\
token=YOUR_API_KEY"
                

To get the data for particular stocks, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getstocksdata



Result example :

{
    "res": [
        {
            "close": 1.68,
            "date": 1262563200000,
            "high": 1.68,
            "index": 2720,
            "low": 1.68,
            "name": "MSNIAGA",
            "open": 1.68,
            "vol": 21000
        },
        {
            "close": 1.71,
            "date": 1262649600000,
            "high": 1.71,
            "index": 2719,
            "low": 1.7,
            "name": "MSNIAGA",
            "open": 1.7,
            "vol": 25000
        },
        {
            "close": 1.79,
            "date": 1262736000000,
            "high": 1.79,
            "index": 2718,
            "low": 1.71,
            "name": "MSNIAGA",
            "open": 1.71,
            "vol": 37000
        },
        {
            "close": 1.82,
            "date": 1262822400000,
            "high": 1.84,
            "index": 2717,
            "low": 1.77,
            "name": "MSNIAGA",
            "open": 1.8,
            "vol": 66000
        }
        ...
    ]
}

                

QUERY PARAMETERS

Field Type Description
stocksname String Stocks name such as MSNIAGA, AIRASIA, 3A and etc..
token String Your API key.

Get Latest Stock Details


curl --location --request GET "https://i-bursa.herokuapp.com/getstockslatest?\
stocksname=MSNIAGA&\
token=YOUR_API_KEY"
                

To get the latest stock details for particular stocks, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getstockslatest



Result example :

{
    "res": {
        "close": "1.25",
        "date": "20 November 2020 04.09 PM",
        "high": 1.25,
        "low": 1.25,
        "name": "MSNIAGA",
        "open": 1.25,
        "volume": "4000"
    }
}

                

QUERY PARAMETERS

Field Type Description
stocksname String Stocks name such as MSNIAGA, AIRASIA, 3A and etc..
token String Your API key.

Get List of Stocks


curl --location --request GET "https://i-bursa.herokuapp.com/getstockslist?\
token=YOUR_API_KEY"
                

To get list of stocks available on this API, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getstockslist



Result example :

{
    "stocks_list": [
        "3A",
        "AASIA",
        "AAX",
        "ABLEGRP",
        "ABMB",
        "ACME",
        "ACO",
        "ACOSTEC",
        "ADVCON",
        "ADVENTA",
        "ADVPKG",
        "AEM",
        ....
        ]
}
                

QUERY PARAMETERS

Field Type Description
token String Your API key.

Get Latest Uptrend MA200 Stocks


curl --location --request GET "https://i-bursa.herokuapp.com/getlatestuptrend?\
token=YOUR_API_KEY"
                

To get latest uptrend MA200 stocks available on this API, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getlatestuptrend



Result example :

{
    "uptrend": [
        {
            "150_Day_Ma": 2.2,
            "200_Day_MA": 2.13,
            "50_Day_MA": 2.29,
            "52_Week_High": 2.55,
            "52_Week_Low": 1.68,
            "Stock": "ADVPKG"
        },
        {
            "150_Day_Ma": 0.63,
            "200_Day_MA": 0.53,
            "50_Day_MA": 0.67,
            "52_Week_High": 0.87,
            "52_Week_Low": 0.08,
            "Stock": "AEMULUS"
        },
        {
            "150_Day_Ma": 0.84,
            "200_Day_MA": 0.8,
            "50_Day_MA": 0.97,
            "52_Week_High": 1.0,
            "52_Week_Low": 0.58,
            "Stock": "AHP"
        },
        ...
        ]
}
                

QUERY PARAMETERS

Field Type Description
token String Your API key.

Get Latest RSI Rating


curl --location --request GET "https://i-bursa.herokuapp.com/getlatestrsi?\
token=YOUR_API_KEY"
                

To get latest relative strength index rating available on this API, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getlatestrsi



Result example :

{
    "rsi": [
        {
            "RS_Rating": 2.39,
            "Stock": "3A"
        },
        {
            "RS_Rating": 10.02,
            "Stock": "AASIA"
        },
        {
            "RS_Rating": 5.9,
            "Stock": "AAX"
        },
        {
            "RS_Rating": 21.93,
            "Stock": "ABLEGRP"
        },
        {
            "RS_Rating": 2.91,
            "Stock": "ABMB"
        },
        ...
        ]
}
                

QUERY PARAMETERS

Field Type Description
token String Your API key.

Get Latest Pivot


curl --location --request GET "https://i-bursa.herokuapp.com/getlatestpivot?\
stocksname=MSNIAGA&\
token=YOUR_API_KEY"
                

To get the latest stock pivot for particular stocks, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getlatestpivot



Result example :

{
    "pivot": [
        {
            "Cama_R1": 1.5988293333,
            "Cama_R2": 1.6043133333,
            "Cama_R3": 1.6098333333,
            "Cama_S1": 1.5878373333,
            "Cama_S2": 1.5823533333,
            "Cama_S3": 1.5768333333,
            "Classic_R1": 1.5666666667,
            "Classic_R2": 1.6533333333,
            "Classic_R3": 1.7133333333,
            "Classic_S1": 1.5666666667,
            "Classic_S2": 1.5333333333,
            "Classic_S3": 1.4733333333,
            "Fibo_R1": 1.6162533333,
            "Fibo_R2": 1.6304133333,
            "Fibo_R3": 1.6533333333,
            "Fibo_S1": 1.5704133333,
            "Fibo_S2": 1.5562533333,
            "Fibo_S3": 1.5333333333,
            "Pivot": 1.5933333333,
            "name": "MSNIAGA"
        }
    ]
}

                

QUERY PARAMETERS

Field Type Description
stocksname String Stocks name such as MSNIAGA, AIRASIA, 3A and etc..
token String Your API key.

Get Latest MACD


curl --location --request GET "https://i-bursa.herokuapp.com/getlatestMACD?\
stocksname=MSNIAGA&\
fast=12&\
slow=26&\
signal=9&\
token=YOUR_API_KEY"
                

To get the latest stock MACD for particular stocks, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getlatestMACD



Result example :

{
    "MACD": [
        {
            "EMA": 1.25,
            "EMA_200": 1.25,
            "MACD": null,
            "MACDhist": null,
            "MACDsig": null,
            "buy_sig": null,
            "close": 1.25,
            "date": "2020-02-25",
            "high": 1.29,
            "low": 1.25,
            "name": "MSNIAGA",
            "open": 1.29,
            "sell_sig": null,
            "vol": 2100.0
        },
        {
            "EMA": 1.25,
            "EMA_200": 1.25,
            "MACD": null,
            "MACDhist": null,
            "MACDsig": null,
            "buy_sig": null,
            "close": 1.25,
            "date": "2020-02-26",
            "high": 1.25,
            "low": 1.25,
            "name": "MSNIAGA",
            "open": 1.25,
            "sell_sig": null,
            "vol": 1100.0
        },
        ...],
    "stocksplot": "iVBORw0KGgoAAAAN......."
}

                

QUERY PARAMETERS

Field Type Description
stocksname String Stocks name such as MSNIAGA, AIRASIA, 3A and etc..
fast String Fast period in integer format such as 1, 2, 3
slow String Slow period in integer format such as 1, 2, 3
signal String Signal period in integer format such as 1, 2, 3
token String Your API key.

Get Latest SAR


curl --location --request GET "https://i-bursa.herokuapp.com/getlatestSAR?\
stocksname=MSNIAGA&\
token=YOUR_API_KEY"
                

To get the latest stock SAR for particular stocks, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getlatestSAR



Result example :

{
    "SAR": [
        {
            "SAR": null,
            "chikou_span": 0.755,
            "close": 1.25,
            "daily_return": null,
            "date": "2020-02-25",
            "high": 1.29,
            "kijun_sen_line": null,
            "low": 1.25,
            "name": "MSNIAGA",
            "open": 1.29,
            "senkou_spna_A": null,
            "senkou_spna_B": null,
            "signal": 0,
            "strategy_returns": null,
            "tenkan_sen_line": null,
            "vol": 2100.0
        },
        {
            "SAR": 1.25,
            "chikou_span": 0.76,
            "close": 1.25,
            "daily_return": 0.0,
            "date": "2020-02-26",
            "high": 1.25,
            "kijun_sen_line": null,
            "low": 1.25,
            "name": "MSNIAGA",
            "open": 1.25,
            "senkou_spna_A": null,
            "senkou_spna_B": null,
            "signal": 0,
            "strategy_returns": 0.0,
            "tenkan_sen_line": null,
            "vol": 1100.0
        },
        ...],
    "stocksplot": "iVBORw0KGgoAAAAN......."
}

                

QUERY PARAMETERS

Field Type Description
stocksname String Stocks name such as MSNIAGA, AIRASIA, 3A and etc..
token String Your API key.

Get Latest Batting Average


curl --location --request GET "https://i-bursa.herokuapp.com/getlatestbattingaverage?\
stocksname=MSNIAGA&\
token=YOUR_API_KEY"
                

To get the latest batting average for particular stocks, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getlatestbattingaverage



Result example :

{
    "average_gain": "4.428243184824339",
    "average_loss": "-13.231226528877865",
    "batting_average": "0.24414715719063546",
    "gainloss_ratio": "0.3346812311889196",
    "max_loss": "-60.560344827586206",
    "max_return": "23.77049180327868",
    "stocksname": "MSNIAGA"
}

                

QUERY PARAMETERS

Field Type Description
stocksname String Stocks name such as MSNIAGA, AIRASIA, 3A and etc..
token String Your API key.

Get Backtesting


curl --location --request GET "https://i-bursa.herokuapp.com/getbacktesting?\
stocksname=MSNIAGA&\
fast=12&\
slow=26&\
signal=20&\
sma=5&\
initial_cash=2000&\
token=YOUR_API_KEY"
                

To do backtesting for particular stocks, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/getbacktesting



Result example :

{
    "backtesting": [
        {
            "add_cash_amount": 0,
            "add_cash_freq": "M",
            "allow_short": false,
            "buy_prop": 1,
            "channel": "",
            "commission": 0.0075,
            "dir_period": 10,
            "drawdown": 17.1460219038,
            "execution_type": "close",
            "fast_period": 12,
            "final_value": 1708.92925,
            "init_cash": 2000,
            "len": 66,
            "max": {
                "drawdown": 18.2214603984,
                "len": 66,
                "moneydown": 375.832125
            },
            "maxdrawdown": 18.2214603984,
            "maxdrawdownperiod": 66,
            "moneydown": 353.65035,
            "pnl": -291.07,
            "ravg": -0.0006445909,
            "rnorm": -0.1499302745,
            "rnorm100": -14.9930274478,
            "rtot": -0.1572801758,
            "sell_prop": 1,
            "sharperatio": -1.4223663936,
            "short_max": 1.5,
            "signal_period": 20,
            "slow_period": 26,
            "sma_period": 5,
            "stop_loss": 0,
            "stop_trail": 0,
            "strat_id": 0,
            "symbol": ""
        }
    ],
    "stocks": "MSNIAGA",
    "stocksplot": "iVBORw0KGgoAAAANSUhEUgAAC7gAAA......."
}

                

QUERY PARAMETERS

Field Type Description
stocksname String Stocks name such as MSNIAGA, AIRASIA, 3A and etc..
fast String Fast period in integer format such as 1, 2, 3
slow String Slow period in integer format such as 1, 2, 3
signal String Signal period in integer format such as 1, 2, 3
sma String SMA period in integer format such as 1, 2, 3
initial_cash String Your preferred initial cash in integer format such as 1, 2, 3
token String Your API key.

Oversold Screener


curl --location --request GET "https://i-bursa.herokuapp.com/oversoldscreener?\
token=YOUR_API_KEY"
                

This screener will list out stocks that satisfy condition that the stocks have close price larger than SMA 50 and RSI values between 40 and 50. To get the list of the stocks using Oversold Screener, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/oversoldscreener



Result example :

{
    "oversold": [
        {
            "Close": 0.075,
            "RSI": 43.6803455994,
            "Sharpe_Ratio": 57.2245448287,
            "Stock": "SAPNRG-WA"
        },
        {
            "Close": 0.315,
            "RSI": 47.7536492585,
            "Sharpe_Ratio": 32.4165952883,
            "Stock": "CENSOF"
        },
        {
            "Close": 6.25,
            "RSI": 49.5705628546,
            "Sharpe_Ratio": 25.8291576565,
            "Stock": "AIRPORT"
        },
        ...
    ]
}

                

QUERY PARAMETERS

Field Type Description
token String Your API key.

Breakout Screener


curl --location --request GET "https://i-bursa.herokuapp.com/breakoutscreener?\
token=YOUR_API_KEY"
                

This screener will list out stocks that satisfy condition that the stocks have close price near 30 days high, close price larger than SMA 50 and RSI values between 50 and 70. To get the list of the stocks using Breakout Screener, you need to make a GET call to the following url :
https://i-bursa.herokuapp.com/breakoutscreener



Result example :

{
    "breakout": [
        {
            "Close": 0.995,
            "RSI": 59.5355973408,
            "Sharpe_Ratio": 29.797679342,
            "Stock": "MGB"
        },
        {
            "Close": 0.66,
            "RSI": 58.9416381759,
            "Sharpe_Ratio": 27.3306291217,
            "Stock": "SRIDGE-WA"
        },
        {
            "Close": 3.43,
            "RSI": 57.6273146852,
            "Sharpe_Ratio": 25.8458629728,
            "Stock": "MBMR"
        },
        ...
    ]
}

                

QUERY PARAMETERS

Field Type Description
token String Your API key.