Class DailyTradingLimit

java.lang.Object
markets.alpaca.client.openapi.broker.model.DailyTradingLimit
All Implemented Interfaces:
Serializable

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.25.0") public class DailyTradingLimit extends Object implements Serializable
Correspondent-level daily net buying limit and the real-time amount currently consuming it.
See Also:
  • Field Details

  • Constructor Details

    • DailyTradingLimit

      public DailyTradingLimit()
  • Method Details

    • cashHeld

      public DailyTradingLimit cashHeld(@Nullable BigDecimal cashHeld)
    • getCashHeld

      @Nullable public BigDecimal getCashHeld()
      Cash reserved for open cash-secured put positions. Only present in the response when the correspondent has at least one open cash-secured put; the field is omitted from the response otherwise (including for options-enabled correspondents with no open cash-secured puts).
      Returns:
      cashHeld
    • setCashHeld

      public void setCashHeld(@Nullable BigDecimal cashHeld)
    • correspondent

      public DailyTradingLimit correspondent(@Nullable String correspondent)
    • getCorrespondent

      @Nullable public String getCorrespondent()
      The correspondent code the limits apply to.
      Returns:
      correspondent
    • setCorrespondent

      public void setCorrespondent(@Nullable String correspondent)
    • dailyNetLimit

      public DailyTradingLimit dailyNetLimit(@Nullable BigDecimal dailyNetLimit)
    • getDailyNetLimit

      @Nullable public BigDecimal getDailyNetLimit()
      The daily net buying limit for the correspondent; further buying is halted once the in_use_limit limit reaches this value.
      Returns:
      dailyNetLimit
    • setDailyNetLimit

      public void setDailyNetLimit(@Nullable BigDecimal dailyNetLimit)
    • executedBuys

      public DailyTradingLimit executedBuys(@Nullable BigDecimal executedBuys)
    • getExecutedBuys

      @Nullable public BigDecimal getExecutedBuys()
      Cumulative cash value of executed buy activity contributing to the in-use limit since the last reset.
      Returns:
      executedBuys
    • setExecutedBuys

      public void setExecutedBuys(@Nullable BigDecimal executedBuys)
    • executedSells

      public DailyTradingLimit executedSells(@Nullable BigDecimal executedSells)
    • getExecutedSells

      @Nullable public BigDecimal getExecutedSells()
      Cumulative cash value of executed sell activity offsetting the in-use limit since the last reset.
      Returns:
      executedSells
    • setExecutedSells

      public void setExecutedSells(@Nullable BigDecimal executedSells)
    • inUseLimit

      public DailyTradingLimit inUseLimit(@Nullable BigDecimal inUseLimit)
    • getInUseLimit

      @Nullable public BigDecimal getInUseLimit()
      Real-time net amount currently consuming the daily limit. Equal to `executed_buys` − `executed_sells` + `open_buys` − `open_sells` (+ `cash_held` when a cash-secured put is open). Resets at the start of the next trading day at 8.00 PM ET.
      Returns:
      inUseLimit
    • setInUseLimit

      public void setInUseLimit(@Nullable BigDecimal inUseLimit)
    • openBuys

      public DailyTradingLimit openBuys(@Nullable BigDecimal openBuys)
    • getOpenBuys

      @Nullable public BigDecimal getOpenBuys()
      Reserved cash value of currently open buy orders (limit price for limit orders, notional or estimated mid for market orders) contributing to the in-use limit.
      Returns:
      openBuys
    • setOpenBuys

      public void setOpenBuys(@Nullable BigDecimal openBuys)
    • openSells

      public DailyTradingLimit openSells(@Nullable BigDecimal openSells)
    • getOpenSells

      @Nullable public BigDecimal getOpenSells()
      Reserved cash value of currently open sell orders offsetting the in-use limit.
      Returns:
      openSells
    • setOpenSells

      public void setOpenSells(@Nullable BigDecimal openSells)
    • putAdditionalProperty

      public DailyTradingLimit putAdditionalProperty(String key, Object value)
      Set the additional (undeclared) property with the specified name and value. If the property does not already exist, create it otherwise replace it.
      Parameters:
      key - name of the property
      value - value of the property
      Returns:
      the DailyTradingLimit instance itself
    • getAdditionalProperties

      public Map<String,Object> getAdditionalProperties()
      Return the additional (undeclared) property.
      Returns:
      a map of objects
    • getAdditionalProperty

      public Object getAdditionalProperty(String key)
      Return the additional (undeclared) property with the specified name.
      Parameters:
      key - name of the property
      Returns:
      an object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • validateJsonElement

      public static void validateJsonElement(com.google.gson.JsonElement jsonElement) throws IOException
      Validates the JSON Element and throws an exception if issues found
      Parameters:
      jsonElement - JSON Element
      Throws:
      IOException - if the JSON Element is invalid with respect to DailyTradingLimit
    • fromJson

      public static DailyTradingLimit fromJson(String jsonString) throws IOException
      Create an instance of DailyTradingLimit given an JSON string
      Parameters:
      jsonString - JSON string
      Returns:
      An instance of DailyTradingLimit
      Throws:
      IOException - if the JSON string is invalid with respect to DailyTradingLimit
    • toJson

      public String toJson()
      Convert an instance of DailyTradingLimit to an JSON string
      Returns:
      JSON string