> ## Documentation Index
> Fetch the complete documentation index at: https://quickoinfosoftprivatelimited.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Foreign Securities Tradewise P&L

> Tradewise P&L helps calculate profit and loss on a trade-level basis

## Overview

The Foreign Securities Tradewise P\&L API provides profit and loss calculations on a trade-level basis for completed foreign transactions. This is critical for Quicko to:

* Calculate realized capital gains and losses on international investments
* Track foreign currency implications and exchange rate impacts
* Segregate transactions by holding period (long-term vs short-term)
* Generate accurate P\&L statements for foreign investment tax compliance
* Track dividend and interest income from foreign securities with TDS deductions
* Identify tax harvesting opportunities on international positions

## Query Parameters

Your API should accept `from` and `to` query parameters to retrieve P\&L data for a specific date range.

```
GET /securities/foreign/tradewise-pnl?from=YYYY-MM-DD&to=YYYY-MM-DD
```

## Response Format

Your API should return matched trade pairs with complete P\&L calculations organized by security type:

## Stock Tradewise Settlement Sheet

### Stock Tradewise Settlement Table

| Param | Type | Description |
| - | - | - |
| isin | string | ISIN is the international security identification number |
| symbol | string | Symbol or description of equity share |
| quantity | number | Trading quantity |
| buy\_trade\_id | string | Transaction ID of the buy transaction |
| buy\_date | number | The date on which the equity stock was bought |
| buy\_price | number | Price at which a unit was bought |
| sell\_trade\_id | string | Transaction ID of the sell transaction |
| sell\_date | number | The date on which the equity stock was sold |
| sell\_price | number | Price at which a unit was sold |
| currency | string | The 3 letter currency code for the price based on ISO 421 |
| transfer\_expenses | number | expense relating to the transfer of stocks |
| nature\_of\_settlement | string | The [nature of the settlement](https://quickoinfosoftprivatelimited.mintlify.site/projects/integration/broker-integration/tradewise_pnl/foreign/foreign_securities_tradewise_pnl.md#annexure-2-nature-of-settlement) of transaction |
| product\_type | string | Indicates whether the order is :delivery , intraday |

### Stock Tradewise Open Sell Table

| Param | Type | Description |
| - | - | - |
| isin | string | ISIN is the international security identification number |
| symbol | string | Symbol or description of equity share |
| quantity | number | Trading quantity |
| sell\_trade\_id | string | Transaction ID of the sell transaction |
| sell\_date | number | The date on which the equity stock was sold |
| sell\_price | number | Price at which a unit was sold |
| currency | string | The 3 letter currency code for the price based on ISO 4217 |
| transaction\_type | string | Indicates whether the order is :buy, sell, trade, send, receive |
| label | string | Indicates the category of transaction type. Possible values: interest, staking, staking\_reward, lost, mining\_reward, airdrop, donation, fork, gift, payment, other\_income |
| last\_traded\_price | number | Last traded price of the security |

### Stock Tradewise Transfer Table

| Param | Type | Description |
| - | - | - |
| isin | string | ISIN is the international security identification number |
| symbol | string | Symbol or description of equity share |
| quantity | number | Trading quantity |
| transfer\_date | number | The date on which the transfer was made |
| price | number | Price at which a unit was transferred |
| currency | string | The 3 letter currency code for the price based on ISO 4217 |
| transfer\_type | string | Indicates whether the transfer is :transfer\_in, transfer\_out |
| nature\_of\_settlement | string | The [nature of the settlement](https://quickoinfosoftprivatelimited.mintlify.site/reference/foreign-securities-tradewise-pl#annexure-2-nature-of-settlement) of transaction |
| transfer\_value | number | total value of transfers made |
| transfer\_expense | number | expenses incurred while transferring the asset. |

### Dividend Table

| Param | Type | Required | Description |
| - | - | - | - |
| isin | string | No | ISIN is the international security identification number |
| scheme\_name | string | Yes | Symbol or description of the fund |
| quantity | number | Yes | Trading quantity |
| date | number | Yes | Transaction epoch timestamp |
| dividend\_amount | number | Yes | Dividend amount received |
| currency | string | Yes | The 3 letter currency code for the price based on ISO 4217 |
| tax\_withheld | number | Yes | TDS amount deducted on the dividend |

## Interest Income Sheet

### Interest Table

| Param | Type | Required | Description |
| - | - | - | - |
| description | string | No | Description of interest credit |
| date | number | Yes | Transaction ID of the particular entry |
| amount | number | Yes | Interest amount received |
| currency | string | Yes | The 3 letter currency code for the price based on ISO 4217 |
| tax\_withheld | number | Yes | TDS amount deducted on the interest |

## Annexures

### Annexure-1 Labels

The enumeration is explained below:

| Corporate Action | ENUM |
| - | - |
| Amalgamation | amalgamation |
| Bonus Issue | bonus\_issue |
| Buy Back of Shares | buy\_back |
| Consolidation of Shares | consolidation |
| Dividend | dividend |
| Dividend on Preference Shares | dividend |
| Income Distribution (InvIT) | income\_distribution\_invit |
| Income Distribution RITES | income\_distribution\_rites |
| InvIT - Return of Capital | return\_of\_capital\_invit |
| Preferential Issue of shares | preferential\_issue |
| Reduction of Capital | reduction\_of\_capital |
| Right Issue of Equity Shares | right\_issue |
| Scheme of Arrangement | scheme\_of\_arrangement |
| Spin Off | spin\_off |
| Stock Split | stock\_split |
| Voluntary Delisting of Shares | voluntary\_delisting\_of\_share |
| Donation of security | donation |
| Transfer of securities in form of gift | gift |
| Loss of security | lost |
| Transfer of securities | transfer |
| Other | other |

### Annexure-2 Nature of Settlement

| Nature of Settlement | ENUM |
| - | - |
| Trade type settlement | trade |
| Interest on security | interest |
| Asset transferred in | transfer\_in |
| Asset transferred out | transfer\_out |
| Asset sent as Gift | gift\_send |
| Asset received as Gift | gift\_receive |
| Asset donated | donation |
| Buy back for the security | buy\_back |
| Other | other |


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