> ## Documentation Index
> Fetch the complete documentation index at: https://developer.sandbox.co.in/llms.txt
> Use this file to discover all available pages before exploring further.

# Overview

> Calculate profit & loss, capital gains tax, indexed costs, and ITR for various asset classes including securities, crypto, real estate, and other investments.

# Income Tax Calculator APIs

The Income Tax Calculator APIs provide comprehensive financial calculation capabilities for investment analysis, tax planning, and compliance. Calculate profit & loss, capital gains tax, indexed costs, and Income Tax Returns across multiple asset classes.

## Key Features

> **[Tax-Aware P\&L](https://developer.sandbox.co.in/api-reference/it/calculator/overview.md#tax-pnl-calculators)**
>
> Calculate profit & loss with automatic capital gains tax classification and indexation benefits.

> **[Basic P\&L](https://developer.sandbox.co.in/api-reference/it/calculator/overview.md#pnl-calculators)**
>
> Compute realized and unrealized gains/losses without tax implications for portfolio analysis.

> **[Indexed Cost Calculator](https://developer.sandbox.co.in/api-reference/it/calculator/income_tax/indexed_cost/Calculate_bulk_Indexed_Cost)**
>
> Calculate indexed acquisition costs for long-term capital gains tax computation.

> **[ITR Calculator](https://developer.sandbox.co.in/api-reference/it/calculator/income_tax/itr/Calculate_itr)**
>
> Prepare and calculate Income Tax Return components for individual taxpayers.

## Asset Classes Supported

### Securities (Domestic & Foreign)

* **Equity Shares**: Delivery and intraday trading
* **Mutual Funds**: SIPs, lump-sum investments, redemptions
* **Derivatives**: Futures, options, and other derivative instruments
* **Currency Impact**: Foreign securities with automatic currency conversion

### Cryptocurrency

* **Digital Assets**: Bitcoin, Ethereum, and other cryptocurrencies
* **Trading Pairs**: Spot and derivative crypto transactions
* **Holding Periods**: Short-term and long-term classification

### Real Estate

* **Property Transactions**: Purchase, sale, and rental income
* **Indexation Benefits**: Long-term capital gains with indexation
* **Rental Calculations**: Income from property rentals

### Other Assets

* **Collectibles**: Art, antiques, and collectible items
* **Precious Metals**: Gold, silver, and other commodities
* **Custom Assets**: User-defined asset classes

## Tax P\&L Calculators

Calculate profit & loss with automatic tax classification and indexation benefits:

> **[Domestic Securities](https://developer.sandbox.co.in/api-reference/it/calculator/tax_pnl/securities/domestic/overview.md)**
>
> Indian market investments with indexation

> **[Foreign Securities](https://developer.sandbox.co.in/api-reference/it/calculator/tax_pnl/securities/foreign/overview.md)**
>
> International investments with currency gains

> **[Cryptocurrency](https://developer.sandbox.co.in/api-reference/it/calculator/tax_pnl/crypto/overview.md)**
>
> Digital asset tax calculations

> **[Real Estate](https://developer.sandbox.co.in/api-reference/it/calculator/tax_pnl/real_estate/real_estate.md)**
>
> Property investment tax analysis

> **[Other Assets](https://developer.sandbox.co.in/api-reference/it/calculator/tax_pnl/other_assets/other.md)**
>
> Collectibles and custom assets

## PnL Calculators

Basic profit & loss calculations for portfolio analysis:

> **[Domestic Securities](https://developer.sandbox.co.in/api-reference/it/calculator/pnl/securities/domestic/endpoints/submit_job.md)**
>
> Indian market P\&L without tax

> **[Foreign Securities](https://developer.sandbox.co.in/api-reference/it/calculator/pnl/securities/foreign/endpoints/submit_job.md)**
>
> International investments P\&L

> **[Cryptocurrency](https://developer.sandbox.co.in/api-reference/it/calculator/pnl/crypto/endpoints/submit_job.md)**
>
> Crypto trading P\&L

> **[Real Estate](https://developer.sandbox.co.in/api-reference/it/calculator/pnl/real_estate/endpoints/real_estate.md)**
>
> Property investment P\&L

> **[Other Assets](https://developer.sandbox.co.in/api-reference/it/calculator/pnl/other_assets/endpoints/other.md)**
>
> Custom asset P\&L calculations

## How It Works

**1. Choose Calculator Type**

Select between Tax P\&L (with tax implications) or basic P\&L (without tax) based on your needs.

**2. Prepare Transaction Data**

Format your investment data in the required JSON structure with trade details, dates, and amounts.

**3. Submit Calculation Job**

Use async job APIs for large datasets with status polling or webhook notifications.

**4. Retrieve Results**

Get detailed P\&L reports with gain/loss classification, tax implications, and summary statistics.

## API Architecture

### Synchronous APIs

* **Indexed Cost Calculator**: Real-time calculations for cost indexation
* **ITR Calculator**: Immediate tax return component calculations
* **Small Datasets**: Direct API responses for smaller transaction sets

### Asynchronous APIs

* **Job-Based Processing**: Large datasets processed in background jobs
* **Status Polling**: Check job completion status
* **Webhook Support**: Real-time notifications for job completion
* **Batch Processing**: Handle thousands of transactions efficiently

## Data Formats

### Transaction Input

```json theme={null}
{
  "symbol": "RELIANCE",
  "quantity": 100,
  "price": 2500.00,
  "date": "2023-01-15",
  "transaction_type": "buy",
  "brokerage": 25.00,
  "exchange_fees": 5.00
}
```

### Calculation Output

```json theme={null}
{
  "total_pnl": 15000.00,
  "realized_gains": 12000.00,
  "unrealized_gains": 3000.00,
  "short_term_gains": 8000.00,
  "long_term_gains": 4000.00,
  "tax_liability": 1200.00
}
```

## Tax Compliance Features

* **Holding Period Classification**: Automatic STCG/LTCG categorization
* **Indexation Benefits**: Cost inflation adjustment for long-term gains
* **Currency Gains**: Foreign exchange impact on international investments
* **Loss Harvesting**: Capital loss tracking for tax optimization
* **Tax Regimes**: Support for old and new tax regimes

## Integration Options

* **REST APIs**: Standard HTTP endpoints for all calculations
* **Postman Collections**: Pre-configured API testing environments
* **SDK Support**: Client libraries for popular programming languages
* **Webhook Integration**: Real-time data synchronization

## Rate Limits & Performance

* **Synchronous APIs**: Up to 100 requests per minute
* **Asynchronous Jobs**: Unlimited job submissions with concurrent processing
* **Data Processing**: Handle up to 10,000 transactions per job
* **Response Times**: Real-time for small datasets, minutes for large jobs

## Support & Resources

* **API Reference**: Complete endpoint documentation with examples
* **Postman Collection**: Import ready-to-use API tests
* **Sample Data**: Pre-formatted transaction data for testing
* **Annexures**: Detailed schema documentation for data formats

For technical support or integration assistance, refer to the [API Reference](https://developer.sandbox.co.in/api-reference/it/calculator) or contact Sandbox support.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.