OVERVIEW
What is the XTS API?
XTS API is a developer toolkit that lets your application read market data and place trades programmatically. Instead of doing everything by hand, you can automate your workflow with clean REST endpoints and subscribe to live updates via WebSocket.
Use it to pull quotes and depth, manage orders (place/modify/cancel), and track positions, holdings, and margins all securely and with low latency. Build anything from simple rules to advanced strategies.
Functionalities of XTS API
Core capabilities you can plug into your app right away.
Real‑Time Market Data
Stream quotes, depth (LTP, bid/ask), and snapshots via WebSocket; pull historical data via REST for analysis.
Order Management
Place, modify, and cancel orders with control over quantity, price, product type, and validity across segments.
Portfolio & Funds
Fetch positions, holdings, margins, and limits to monitor risk and build your own portfolio dashboards.
Authentication & Sessions
Secure token‑based auth for REST and WebSocket connections, so all calls and streams remain protected.
Understanding the API Flow
This interactive diagram illustrates the typical communication flow between your application and the PESB API. Each step shows how authentication, requests, and data flow work together for successful integration.
Login Request
Your application sends a secure POST request with your API key and secret to the authentication endpoint. This establishes your identity with the system.
{ "appKey": "your_key", "secretKey": "your_secret", "source": "your_source" }
Receive Token
Upon successful authentication, the API returns a temporary JWT token. This token is your access pass for all subsequent API calls.
Make API Calls
Include the token in the Authorization header to access protected endpoints. Place orders, check positions, or fetch market data securely.
Connect WebSocket
Use the same token to establish a WebSocket connection for real-time data streaming. Subscribe to live market feeds and order updates instantly.
Choose Your Plan
Find the perfect plan that fits your trading needs, whether you are an individual developer or an institutional firm.
Free Trial
₹0
/ 1 month
- NSE Cash, BSE Cash, MCX & F&O
- Place, modify, and cancel orders with supported brokers
- WebSocket depth, OHLC, and trades
Monthly
₹450
/ month
- NSE Cash, BSE Cash, MCX & F&O
- Place, modify, and cancel orders with supported brokers
- WebSocket depth, OHLC, and trades
6 Month
₹2000
/ 6 months
- NSE Cash, BSE Cash, MCX & F&O
- Place, modify, and cancel orders with supported brokers
- WebSocket depth, OHLC, and trades
12 Month
₹2700
/ year
- NSE Cash, BSE Cash, MCX & F&O
- Place, modify, and cancel orders with supported brokers
- WebSocket depth, OHLC, and trades
Get Started in 4 Simple Steps
Starting your development journey with the PESB API is straightforward. Follow these steps to get your credentials, explore the documentation, and begin building your application. This structured path ensures you have everything you need for a smooth and successful integration.
Register for API Access
Contact the PESB team to get your API key and secret. This is your unique identifier for accessing the system.
Explore the Documentation
Dive into our comprehensive API documentation to understand all the available endpoints, parameters, and data formats.
Build Your Application
Start integrating the API into your application. Use your preferred programming language to make HTTP requests to our endpoints.
Test and Deploy
Thoroughly test your integration in a sandbox environment. Once you are confident, you can move to production and launch your platform.
DOCUMENTATION
Documentation of XTS API
XTS API is REST based Trading API. This will help you to develop trading and investment platform. Open the guides to see endpoints, parameters, and examples.