Class SignedAgreement

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

@Generated(value="org.openapitools.codegen.languages.JavaClientCodegen", comments="Generator version: 7.28.0") public class SignedAgreement extends Object implements Serializable
A signed agreement between a party and Alpaca, as returned by `POST /v1/agreements`. Includes both per-party and per-account agreements.
See Also:
  • Field Details

  • Constructor Details

    • SignedAgreement

      public SignedAgreement()
  • Method Details

    • accountId

      public SignedAgreement accountId(@Nullable UUID accountId)
    • getAccountId

      @Nullable public UUID getAccountId()
      The account associated with this agreement. Present for per-account agreements such as `customer_agreement`, `account_agreement`, `options_agreement`, `master_securities_lending_agreement`, `crypto_agreement`, `dvp_customer_agreement`, `etc_agreement`, and `joint_account_agreement`.
      Returns:
      accountId
    • setAccountId

      public void setAccountId(@Nullable UUID accountId)
    • agreement

      public SignedAgreement agreement(@Nonnull SignedAgreementType agreement)
    • getAgreement

      @Nonnull public SignedAgreementType getAgreement()
      Get agreement
      Returns:
      agreement
    • setAgreement

      public void setAgreement(@Nonnull SignedAgreementType agreement)
    • ipAddress

      public SignedAgreement ipAddress(@Nonnull String ipAddress)
    • getIpAddress

      @Nonnull public String getIpAddress()
      The IP address from which the agreement was signed
      Returns:
      ipAddress
    • setIpAddress

      public void setIpAddress(@Nonnull String ipAddress)
    • partyId

      public SignedAgreement partyId(@Nonnull UUID partyId)
    • getPartyId

      @Nonnull public UUID getPartyId()
      The party that signed the agreement
      Returns:
      partyId
    • setPartyId

      public void setPartyId(@Nonnull UUID partyId)
    • revision

      public SignedAgreement revision(@Nullable String revision)
    • getRevision

      @Nullable public String getRevision()
      The agreement revision. The format is `XX.YYYY.MM` where XX is an incrementing revision number, YYYY is the year and MM is the month. If the revision is not specified in the request, the active revision will be used, which will align with the [Alpaca Documents Library](https://alpaca.markets/disclosures). Omitted for agreement types that do not support revisions (`nasdaq_agreement`, `nyse_agreement`, `oauth_api_agreement`).
      Returns:
      revision
    • setRevision

      public void setRevision(@Nullable String revision)
    • signedAt

      public SignedAgreement signedAt(@Nonnull OffsetDateTime signedAt)
    • getSignedAt

      @Nonnull public OffsetDateTime getSignedAt()
      The timestamp when the agreement was signed
      Returns:
      signedAt
    • setSignedAt

      public void setSignedAt(@Nonnull OffsetDateTime signedAt)
    • signerPartyId

      public SignedAgreement signerPartyId(@Nullable UUID signerPartyId)
    • getSignerPartyId

      @Nullable public UUID getSignerPartyId()
      The party ID of the authorized signer who signed on behalf of a legal entity. Required for legal entity parties.
      Returns:
      signerPartyId
    • setSignerPartyId

      public void setSignerPartyId(@Nullable UUID signerPartyId)
    • 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 SignedAgreement
    • fromJson

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

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