All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.upstox.api.TradeWiseProfitAndLossData Maven / Gradle / Ivy

/*
 * Upstox Developer API
 * Build your App on the Upstox platform  ![Banner](https://api-v2.upstox.com/api-docs/images/banner.jpg \"banner\")  # Introduction  Upstox API is a set of rest APIs that provide data required to build a complete investment and trading platform. Execute orders in real time, manage user portfolio, stream live market data (using Websocket), and more, with the easy to understand API collection.  All requests are over HTTPS and the requests are sent with the content-type ‘application/json’. Developers have the option of choosing the response type as JSON or CSV for a few API calls.  To be able to use these APIs you need to create an App in the Developer Console and generate your **apiKey** and **apiSecret**. You can use a redirect URL which will be called after the login flow.  If you are a **trader**, you can directly create apps from Upstox mobile app or the desktop platform itself from **Apps** sections inside the **Account** Tab. Head over to account.upstox.com/developer/apps.
If you are a **business** looking to integrate Upstox APIs, reach out to us and we will get a custom app created for you in no time. It is highly recommended that you do not embed the **apiSecret** in your frontend app. Create a remote backend which does the handshake on behalf of the frontend app. Marking the apiSecret in the frontend app will make your app vulnerable to threats and potential issues. * * OpenAPI spec version: v2 * * * NOTE: This class is auto generated by the swagger code generator program. * https://github.com/swagger-api/swagger-codegen.git * Do not edit the class manually. */ package com.upstox.api; import java.util.Objects; import java.util.Arrays; import com.google.gson.TypeAdapter; import com.google.gson.annotations.JsonAdapter; import com.google.gson.annotations.SerializedName; import com.google.gson.stream.JsonReader; import com.google.gson.stream.JsonWriter; import io.swagger.v3.oas.annotations.media.Schema; import java.io.IOException; /** * Response data for trade wise data details */ @Schema(description = "Response data for trade wise data details") @javax.annotation.Generated(value = "io.swagger.codegen.v3.generators.java.JavaClientCodegen", date = "2023-07-12T20:29:09.823661+05:30[Asia/Kolkata]") public class TradeWiseProfitAndLossData { @SerializedName("quantity") private Float quantity = null; @SerializedName("isin") private String isin = null; @SerializedName("scrip_name") private String scripName = null; @SerializedName("trade_type") private String tradeType = null; @SerializedName("buy_date") private String buyDate = null; @SerializedName("buy_average") private Float buyAverage = null; @SerializedName("sell_date") private String sellDate = null; @SerializedName("sell_average") private Float sellAverage = null; @SerializedName("buy_amount") private Float buyAmount = null; @SerializedName("sell_amount") private Float sellAmount = null; /** * The quantity of stock traded * @return quantity **/ @Schema(example = "100", description = "The quantity of stock traded") public Float getQuantity() { return quantity; } /** * ISIN of the stock * @return isin **/ @Schema(example = "INE256A01028", description = "ISIN of the stock") public String getIsin() { return isin; } /** * Name of the scrip traded * @return scripName **/ @Schema(example = "ZEE ENTER", description = "Name of the scrip traded") public String getScripName() { return scripName; } /** * FUT - Futures OPT - Options EQ - Equity * @return tradeType **/ @Schema(example = "EQ", description = "FUT - Futures OPT - Options EQ - Equity") public String getTradeType() { return tradeType; } /** * The date on which the stock was bought * @return buyDate **/ @Schema(example = "14-09-2021", description = "The date on which the stock was bought") public String getBuyDate() { return buyDate; } /** * The average rate at which each quantity of the stock was bought * @return buyAverage **/ @Schema(example = "12345.67", description = "The average rate at which each quantity of the stock was bought") public Float getBuyAverage() { return buyAverage; } /** * The date on which the stock was sold * @return sellDate **/ @Schema(example = "14-09-2021", description = "The date on which the stock was sold") public String getSellDate() { return sellDate; } /** * The average rate at which each quantity of the stock was sold * @return sellAverage **/ @Schema(example = "12345.67", description = "The average rate at which each quantity of the stock was sold") public Float getSellAverage() { return sellAverage; } /** * Total buy amount * @return buyAmount **/ @Schema(example = "12345.67", description = "Total buy amount") public Float getBuyAmount() { return buyAmount; } /** * Total sell amount * @return sellAmount **/ @Schema(example = "12345.67", description = "Total sell amount") public Float getSellAmount() { return sellAmount; } @Override public boolean equals(java.lang.Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } TradeWiseProfitAndLossData tradeWiseProfitAndLossData = (TradeWiseProfitAndLossData) o; return Objects.equals(this.quantity, tradeWiseProfitAndLossData.quantity) && Objects.equals(this.isin, tradeWiseProfitAndLossData.isin) && Objects.equals(this.scripName, tradeWiseProfitAndLossData.scripName) && Objects.equals(this.tradeType, tradeWiseProfitAndLossData.tradeType) && Objects.equals(this.buyDate, tradeWiseProfitAndLossData.buyDate) && Objects.equals(this.buyAverage, tradeWiseProfitAndLossData.buyAverage) && Objects.equals(this.sellDate, tradeWiseProfitAndLossData.sellDate) && Objects.equals(this.sellAverage, tradeWiseProfitAndLossData.sellAverage) && Objects.equals(this.buyAmount, tradeWiseProfitAndLossData.buyAmount) && Objects.equals(this.sellAmount, tradeWiseProfitAndLossData.sellAmount); } @Override public int hashCode() { return Objects.hash(quantity, isin, scripName, tradeType, buyDate, buyAverage, sellDate, sellAverage, buyAmount, sellAmount); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class TradeWiseProfitAndLossData {\n"); sb.append(" quantity: ").append(toIndentedString(quantity)).append("\n"); sb.append(" isin: ").append(toIndentedString(isin)).append("\n"); sb.append(" scripName: ").append(toIndentedString(scripName)).append("\n"); sb.append(" tradeType: ").append(toIndentedString(tradeType)).append("\n"); sb.append(" buyDate: ").append(toIndentedString(buyDate)).append("\n"); sb.append(" buyAverage: ").append(toIndentedString(buyAverage)).append("\n"); sb.append(" sellDate: ").append(toIndentedString(sellDate)).append("\n"); sb.append(" sellAverage: ").append(toIndentedString(sellAverage)).append("\n"); sb.append(" buyAmount: ").append(toIndentedString(buyAmount)).append("\n"); sb.append(" sellAmount: ").append(toIndentedString(sellAmount)).append("\n"); sb.append("}"); return sb.toString(); } /** * Convert the given object to string with each line indented by 4 spaces * (except the first line). */ private String toIndentedString(java.lang.Object o) { if (o == null) { return "null"; } return o.toString().replace("\n", "\n "); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy