# APIs & Algo Trading

**URL:** https://community.delta.exchange/c/apis-algo-trading/6.md?page=1

[Latest](https://community.delta.exchange/latest.md) · [Categories](https://community.delta.exchange/categories.md) · [Tags](https://community.delta.exchange/tags.md)

**Page:** 2

---

## [How to fetch next funding rate for BTCUSD / ETHUSD futures via API?](https://community.delta.exchange/t/how-to-fetch-next-funding-rate-for-btcusd-ethusd-futures-via-api/2204)

<div class="topic-metadata">

**Author:** [@Venkat](https://community.delta.exchange/u/Venkat)\
**Replies:** 5\
**Last updated:** [November 18, 2025, 7:16am UTC](https://community.delta.exchange/t/how-to-fetch-next-funding-rate-for-btcusd-ethusd-futures-via-api/2204 "2025-11-18T07:16:53Z")

</div>

Hello Team, I am building an automated trading system using Delta Exchange APIs. I need to programmatically fetch the next funding rate and funding timestamp for the perpetual futures pairs BTCUSD and ETHUSD. I have c…

---

## [About editing bracket order](https://community.delta.exchange/t/about-editing-bracket-order/716)

<div class="topic-metadata">

**Author:** [@onsksingh](https://community.delta.exchange/u/onsksingh)\
**Replies:** 5\
**Last updated:** [November 16, 2025, 5:58pm UTC](https://community.delta.exchange/t/about-editing-bracket-order/716 "2025-11-16T17:58:48Z")

</div>

I have first placed a bracket order on the current order. But now when I am trying to edit the bracket order through bracket order url i.e. requests.put(‘https://api.india.delta.exchange/v2/orders/bracket’, headers=head…

---

## [Webhook Integration](https://community.delta.exchange/t/webhook-integration/2174)

<div class="topic-metadata">

**Author:** [@Biscuit](https://community.delta.exchange/u/Biscuit)\
**Replies:** 5\
**Last updated:** [October 13, 2025, 7:33am UTC](https://community.delta.exchange/t/webhook-integration/2174 "2025-10-13T07:33:11Z")

</div>

Is it possible to a place limit order using webhook from TradingView? Otherwise TradingView firers market orders on candle closing bases.

---

## [A new Python SDK needs more robust and descriptive](https://community.delta.exchange/t/a-new-python-sdk-needs-more-robust-and-descriptive/2169)

<div class="topic-metadata">

**Author:** [@sanskarbharti](https://community.delta.exchange/u/sanskarbharti)\
**Replies:** 1\
**Last updated:** [October 5, 2025, 5:31am UTC](https://community.delta.exchange/t/a-new-python-sdk-needs-more-robust-and-descriptive/2169 "2025-10-05T05:31:37Z")

</div>

trying to fetch historical data using from\_date and to\_date, if on 2025-10-04 using below values getting values only from 3/10/2025 1:58:00 PM to 3/10/2025 4:12:00 PM. Just need to know the availability of historical d…

---

## [Trading bot of delta exchange not execute the trade while trading view give alert please guide what can i do to resolve it](https://community.delta.exchange/t/trading-bot-of-delta-exchange-not-execute-the-trade-while-trading-view-give-alert-please-guide-what-can-i-do-to-resolve-it/2152)

<div class="topic-metadata">

**Author:** [@RAHUETHL](https://community.delta.exchange/u/RAHUETHL)\
**Replies:** 1\
**Last updated:** [September 23, 2025, 5:38am UTC](https://community.delta.exchange/t/trading-bot-of-delta-exchange-not-execute-the-trade-while-trading-view-give-alert-please-guide-what-can-i-do-to-resolve-it/2152 "2025-09-23T05:38:12Z")

</div>

---

## [Access issue while callling api](https://community.delta.exchange/t/access-issue-while-callling-api/2126)

<div class="topic-metadata">

**Author:** [@sivakumar.vee1110](https://community.delta.exchange/u/sivakumar.vee1110)\
**Replies:** 1\
**Last updated:** [September 13, 2025, 6:29am UTC](https://community.delta.exchange/t/access-issue-while-callling-api/2126 "2025-09-13T06:29:35Z")

</div>

Hi Team I am using access issue Status Code: 401 Response Body: {“error”:“unauthorized”,“success”:false} def place\_order(side=“buy”, size=0.9): endpoint = "/v2/orders" url = BASE\_URL + endpoint payload = { "p…

---

## [Limit order via ALGO - trading view webhook](https://community.delta.exchange/t/limit-order-via-algo-trading-view-webhook/1726)

<div class="topic-metadata">

**Author:** [@theCinematic](https://community.delta.exchange/u/theCinematic)\
**Replies:** 4\
**Last updated:** [August 19, 2025, 12:30pm UTC](https://community.delta.exchange/t/limit-order-via-algo-trading-view-webhook/1726 "2025-08-19T12:30:07Z")

</div>

Hi Folks, may i please know, limit order via ALGO - trading view webhook is possible? currently market orders are getting punched. also apart from below payload, anything else is available, which can be used? {“symbo…

---

## [Tradingview send alert but not excute trade on delta exchange inida problem](https://community.delta.exchange/t/tradingview-send-alert-but-not-excute-trade-on-delta-exchange-inida-problem/1863)

<div class="topic-metadata">

**Author:** [@sukshal](https://community.delta.exchange/u/sukshal)\
**Replies:** 3\
**Last updated:** [August 16, 2025, 1:14pm UTC](https://community.delta.exchange/t/tradingview-send-alert-but-not-excute-trade-on-delta-exchange-inida-problem/1863 "2025-08-16T13:14:20Z")

</div>

tradingview send alert but not excute trade problem my captial $100 and order size 1 quntity trading view subsction free 30 day plan use for new customer which plan chose for buy sugest ?

---

## [CCXT library and authentication](https://community.delta.exchange/t/ccxt-library-and-authentication/1959)

<div class="topic-metadata">

**Author:** [@Dharmender](https://community.delta.exchange/u/Dharmender)\
**Replies:** 1\
**Last updated:** [August 12, 2025, 5:11am UTC](https://community.delta.exchange/t/ccxt-library-and-authentication/1959 "2025-08-12T05:11:33Z")

</div>

Hey Team, I’m trying to setup CCXT library to expediate development in .Net 8 for POC. I’m using NuGet Gallery | ccxt 4.4.99 package. I tried to setup things and just for now exploring demo account where I have generat…

---

## [Tradingview show me alert but delta exchange not excute order and failed message](https://community.delta.exchange/t/tradingview-show-me-alert-but-delta-exchange-not-excute-order-and-failed-message/1901)

<div class="topic-metadata">

**Author:** [@sukshal](https://community.delta.exchange/u/sukshal)\
**Replies:** 1\
**Last updated:** [August 5, 2025, 8:52am UTC](https://community.delta.exchange/t/tradingview-show-me-alert-but-delta-exchange-not-excute-order-and-failed-message/1901 "2025-08-05T08:52:31Z")

</div>

use total captail 90 % of equity use tarde futher i want how some change sugest me sir please ! how decimal convert integar pine script trdaingview which plan select for subscribe show me details CUREENT USE FREE 30 DAY…

---

## [Getting wrong Historical data using API](https://community.delta.exchange/t/getting-wrong-historical-data-using-api/767)

<div class="topic-metadata">

**Author:** [@Prashant\_Panchal](https://community.delta.exchange/u/Prashant_Panchal)\
**Replies:** 9\
**Last updated:** [July 8, 2025, 3:11pm UTC](https://community.delta.exchange/t/getting-wrong-historical-data-using-api/767 "2025-07-08T15:11:47Z")

</div>

I am trying to fetch 1 min data from Delta Exchange India, which is getting wrong because It is not matching with the actual price on chart. This data I am getting :: close high low open …

---

## [Wrong price while fetching OHLC using api](https://community.delta.exchange/t/wrong-price-while-fetching-ohlc-using-api/810)

<div class="topic-metadata">

**Author:** [@8891703567](https://community.delta.exchange/u/8891703567)\
**Replies:** 5\
**Last updated:** [July 8, 2025, 12:21pm UTC](https://community.delta.exchange/t/wrong-price-while-fetching-ohlc-using-api/810 "2025-07-08T12:21:44Z")

</div>

I am getting result of “result”: \[ { “close”: 52226.5, “high”: 52432.5, “low”: 52224, “open”: 52420.5, “time”: 1708298700, “volume”: 3621 }, { “close”: 52410.5, “high”: 52431, “low”: 52395, “open”: 52431, …

---

## [Stop price and limit price](https://community.delta.exchange/t/stop-price-and-limit-price/1425)

<div class="topic-metadata">

**Author:** [@johngeorge](https://community.delta.exchange/u/johngeorge)\
**Replies:** 2\
**Last updated:** [June 18, 2025, 4:09pm UTC](https://community.delta.exchange/t/stop-price-and-limit-price/1425 "2025-06-18T16:09:16Z")

</div>

for bracket orders its given » stop\_price string false none Stop loss price level » limit\_price string false none required for limit orders so i just wanted a clarity on which is the trigger price and which would be t…

---

## [How to Place Bracket Orders via API](https://community.delta.exchange/t/how-to-place-bracket-orders-via-api/821)

<div class="topic-metadata">

**Author:** [@midhun](https://community.delta.exchange/u/midhun)\
**Replies:** 13\
**Last updated:** [June 17, 2025, 5:39am UTC](https://community.delta.exchange/t/how-to-place-bracket-orders-via-api/821 "2025-06-17T05:39:15Z")

</div>

Hi Delta Exchange Team, I am using the Delta Exchange API for trading and would like to understand how to place bracket orders via API. Specifically, I want to: Place a buy order when the price reaches a certain level…

---

## [Need to understand , how to get active positions, documentation isn't clear enough](https://community.delta.exchange/t/need-to-understand-how-to-get-active-positions-documentation-isnt-clear-enough/1252)

<div class="topic-metadata">

**Author:** [@syamdevendla](https://community.delta.exchange/u/syamdevendla)\
**Replies:** 1\
**Last updated:** [May 16, 2025, 6:18am UTC](https://community.delta.exchange/t/need-to-understand-how-to-get-active-positions-documentation-isnt-clear-enough/1252 "2025-05-16T06:18:18Z")

</div>

I have used position end point and got the response, Need to understand what does it mean? if result is false that means requested product\_id/asset is not available? if true? what is the size=0 means?

---

## [Unable to change the leverage using Node JS SDK](https://community.delta.exchange/t/unable-to-change-the-leverage-using-node-js-sdk/1093)

<div class="topic-metadata">

**Author:** [@AnilKK](https://community.delta.exchange/u/AnilKK)\
**Replies:** 3\
**Last updated:** [April 30, 2025, 5:47am UTC](https://community.delta.exchange/t/unable-to-change-the-leverage-using-node-js-sdk/1093 "2025-04-30T05:47:18Z")

</div>

Hi, I am trying to change the leverage for BTCUSD with the below code in NodeJS, but throwing error, can anybody please help new DeltaRestClient(vApiKey, vApiSecret).then(client =\> { client.apis.Orders.changeOrderL…

---

## [Algo trading functions](https://community.delta.exchange/t/algo-trading-functions/857)

<div class="topic-metadata">

**Author:** [@naren](https://community.delta.exchange/u/naren)\
**Replies:** 11\
**Last updated:** [March 26, 2025, 2:18pm UTC](https://community.delta.exchange/t/algo-trading-functions/857 "2025-03-26T14:18:22Z")

</div>

import datetime as dt from datetime import datetime, timedelta import pandas as pd import json import sys import hmac import hashlib import time from typing import List from websocket import WebSocketApp import…

---

## [Error fetching position data through API](https://community.delta.exchange/t/error-fetching-position-data-through-api/927)

<div class="topic-metadata">

**Author:** [@noushad](https://community.delta.exchange/u/noushad)\
**Replies:** 3\
**Last updated:** [March 26, 2025, 12:06pm UTC](https://community.delta.exchange/t/error-fetching-position-data-through-api/927 "2025-03-26T12:06:06Z")

</div>

I am using python. Occasionally I get the position details but some times I get the following error message. Failed to fetch positions. HTTP Status Code: 401 Response: {“error”:{“code”:“expired\_signature”,“context”:{“r…

---

## [Any api to fetch the expiry dates?](https://community.delta.exchange/t/any-api-to-fetch-the-expiry-dates/908)

<div class="topic-metadata">

**Author:** [@nagesh.yellapu](https://community.delta.exchange/u/nagesh.yellapu)\
**Replies:** 1\
**Last updated:** [March 17, 2025, 7:26pm UTC](https://community.delta.exchange/t/any-api-to-fetch-the-expiry-dates/908 "2025-03-17T19:26:13Z")

</div>

Hi all, Is there any API to fetch the next expiry dates. The below is text from the api documentation. I want to pass {"symbols": \["BTC-310524"\] } , but for that, I would need to know the next expiry dates for the asse…

---

## [Error while fetching positions](https://community.delta.exchange/t/error-while-fetching-positions/670)

<div class="topic-metadata">

**Author:** [@sourabhg](https://community.delta.exchange/u/sourabhg)\
**Replies:** 2\
**Last updated:** [January 4, 2025, 10:33am UTC](https://community.delta.exchange/t/error-while-fetching-positions/670 "2025-01-04T10:33:33Z")

</div>

I am trying to fetch positions using my php code. my many other requests are working fine both ‘GET’ and ‘POST’. But while trying to fetch positions using GET request, i am unable to do so. instead i get the error sayi…

---

## [Get Order by client oid](https://community.delta.exchange/t/get-order-by-client-oid/890)

<div class="topic-metadata">

**Author:** [@nagesh.yellapu](https://community.delta.exchange/u/nagesh.yellapu)\
**Replies:** 5\
**Last updated:** [March 13, 2025, 3:40pm UTC](https://community.delta.exchange/t/get-order-by-client-oid/890 "2025-03-13T15:40:06Z")

</div>

The API is not behaving the way as it is documented Delta Exchange Api GET /orders/client\_order\_id/{client\_oid} Order was created successfully with the client\_order\_id def get\_order\_by\_client\_id(self, client\_order\_…

---

## [How to delete position orders :](https://community.delta.exchange/t/how-to-delete-position-orders/897)

<div class="topic-metadata">

**Author:** [@arbaz00789](https://community.delta.exchange/u/arbaz00789)\
**Replies:** 1\
**Last updated:** [March 11, 2025, 11:44am UTC](https://community.delta.exchange/t/how-to-delete-position-orders/897 "2025-03-11T11:44:10Z")

</div>

Hi, Is there any way that i can delete my position orders with the following details which we get from getPosition api sample code. response = client.request("GET", "/v2/positions",payload=None, query={"underlying\_asse…

---

## [IP Not Whitelisted Error in Delta Exchange API Even After Adding IP](https://community.delta.exchange/t/ip-not-whitelisted-error-in-delta-exchange-api-even-after-adding-ip/689)

<div class="topic-metadata">

**Author:** [@midhun](https://community.delta.exchange/u/midhun)\
**Replies:** 2\
**Last updated:** [March 7, 2025, 6:28pm UTC](https://community.delta.exchange/t/ip-not-whitelisted-error-in-delta-exchange-api-even-after-adding-ip/689 "2025-03-07T18:28:07Z")

</div>

Hi, I’m getting the following error when trying to connect to the Delta Exchange API: {'error': {'code': 'ip\_not\_whitelisted\_for\_api\_key', 'context': {'client\_ip': 'xx.xx.xx.xx'}}, 'success': False} I have already add…

---

## [Create Order Fail](https://community.delta.exchange/t/create-order-fail/868)

<div class="topic-metadata">

**Author:** [@arbaz00789](https://community.delta.exchange/u/arbaz00789)\
**Replies:** 3\
**Last updated:** [March 7, 2025, 8:02am UTC](https://community.delta.exchange/t/create-order-fail/868 "2025-03-07T08:02:05Z")

</div>

Am using from delta\_rest\_client import DeltaRestClient to place order this is my actual code. from delta\_rest\_client import DeltaRestClient def place\_order(): response = delta\_client.place\_order( product\_id…

---

## [Order Placed Successfully: {'error': {'code': 'Signature Mismatch', 'context': {'signature\_data': 'POST1740429645/v2/orders{"product\_id": 27, "size": 1, "order\_type": "market\_order", "side": "buy"}'}}, 'success': False}](https://community.delta.exchange/t/order-placed-successfully-error-code-signature-mismatch-context-signature-data-post1740429645-v2-orders-product-id-27-size-1-order-type-market-order-side-buy-success-false/831)

<div class="topic-metadata">

**Author:** [@suvendu](https://community.delta.exchange/u/suvendu)\
**Replies:** 3\
**Last updated:** [March 4, 2025, 9:20am UTC](https://community.delta.exchange/t/order-placed-successfully-error-code-signature-mismatch-context-signature-data-post1740429645-v2-orders-product-id-27-size-1-order-type-market-order-side-buy-success-false/831 "2025-03-04T09:20:04Z")

</div>

hiiii , i create a strategy for buying BTCUSD & Condition satisfied bt delta exchange India terminal can’t place order , show this sms in code terminal "Order Placed Successfully: {'error': {'code': 'Sig…

---

## [Not Getting active, orders place in delta indian prod server](https://community.delta.exchange/t/not-getting-active-orders-place-in-delta-indian-prod-server/844)

<div class="topic-metadata">

**Author:** [@arbaz00789](https://community.delta.exchange/u/arbaz00789)\
**Replies:** 1\
**Last updated:** [March 3, 2025, 4:32am UTC](https://community.delta.exchange/t/not-getting-active-orders-place-in-delta-indian-prod-server/844 "2025-03-03T04:32:22Z")

</div>

I have place live trade in delta exchange (India) server, trade is visible but while fetching trade from api am getting empty response, code shared below. One Catch If order are place with stoploss and targetprice we g…

---

## [How to fetch LTP of options price](https://community.delta.exchange/t/how-to-fetch-ltp-of-options-price/819)

<div class="topic-metadata">

**Author:** [@harsh12092002](https://community.delta.exchange/u/harsh12092002)\
**Replies:** 2\
**Last updated:** [February 23, 2025, 7:18am UTC](https://community.delta.exchange/t/how-to-fetch-ltp-of-options-price/819 "2025-02-23T07:18:02Z")

</div>

how to fetch LTP of options…pls tell me variable name or example code …i am having trouble with fetching that

---

## [API to code any setup](https://community.delta.exchange/t/api-to-code-any-setup/803)

<div class="topic-metadata">

**Author:** [@ashishrawat](https://community.delta.exchange/u/ashishrawat)\
**Replies:** 4\
**Last updated:** [February 17, 2025, 4:29am UTC](https://community.delta.exchange/t/api-to-code-any-setup/803 "2025-02-17T04:29:13Z")

</div>

Hi, is there any way possible if we can use Python API to deploy our setup. e.g. if I use 9 ema and 21 ema and I want to place a long order at crossover and a short order for crossunder. So I want to scan all charts usin…

---

## [Candle data and mark price not matching with he candles seen on trading terminal](https://community.delta.exchange/t/candle-data-and-mark-price-not-matching-with-he-candles-seen-on-trading-terminal/764)

<div class="topic-metadata">

**Author:** [@MangeshGaikwad](https://community.delta.exchange/u/MangeshGaikwad)\
**Replies:** 2\
**Last updated:** [January 30, 2025, 3:22am UTC](https://community.delta.exchange/t/candle-data-and-mark-price-not-matching-with-he-candles-seen-on-trading-terminal/764 "2025-01-30T03:22:23Z")

</div>

// subscription DELTA\_WS\_URL = “wss://socket.delta.exchange” SUBSCRIBE\_MESSAGE = { “type”: “subscribe”, “payload”: { “channels”: \[ {“name”: “candlestick\_1m”, “symbols”: \[“BTCUSD”\]}, {“name”: “candlestick\_15m”, …

---

## [How to get All the tickers (Futures only) along with LTP and OHLC](https://community.delta.exchange/t/how-to-get-all-the-tickers-futures-only-along-with-ltp-and-ohlc/747)

<div class="topic-metadata">

**Author:** [@TKD](https://community.delta.exchange/u/TKD)\
**Replies:** 2\
**Last updated:** [January 27, 2025, 3:22am UTC](https://community.delta.exchange/t/how-to-get-all-the-tickers-futures-only-along-with-ltp-and-ohlc/747 "2025-01-27T03:22:55Z")

</div>

Can anyone help me with the code to get All the tickers (Futures only) along with LTP ( mak Price) and OHLC for multiple time frames ( Like 1 min, 5 min, 15 min, 30 min, 1 hr, day, week, month)

[Previous page](https://community.delta.exchange/c/apis-algo-trading/6.md)

[Next page](https://community.delta.exchange/c/apis-algo-trading/6.md?page=2)
