Class Account

java.lang.Object
com.vonage.client.JsonableBaseObject
com.vonage.client.subaccounts.Account
All Implemented Interfaces:
Jsonable

public class Account extends JsonableBaseObject
Represents a subaccount.
  • Constructor Details

  • Method Details

    • getApiKey

      public String getApiKey()
      Unique subaccount ID.
      Returns:
      The subaccount API key.
    • getPrimaryAccountApiKey

      Unique primary account ID.
      Returns:
      The primary account API key.
    • getName

      public String getName()
      Name of the subaccount.
      Returns:
      The subaccount name.
    • getSecret

      public String getSecret()
      API secret of the subaccount.
      Returns:
      The subaccount secret if available, or null if redacted for this response.
    • getUsePrimaryAccountBalance

      Flag showing if balance is shared with primary account.
      Returns:
      Whether the balance is shared with the primary account.
    • getSuspended

      Subaccount suspension status.
      Returns:
      Whether this subaccount has been suspended.
    • getCreatedAt

      Subaccount creation date and time.
      Returns:
      The subaccount creation timestamp in ISO 8601 format.
    • getBalance

      Balance of the subaccount.
      Returns:
      The subaccount balance, or null if it is shared with primary account.
    • getCreditLimit

      Credit limit of the subaccount.
      Returns:
      The subaccount credit limit, or null if it is shared with primary account.
    • fromJson

      public static Account fromJson(String json)
      Creates an instance of this class from a JSON payload.
      Parameters:
      json - The JSON string to parse.
      Returns:
      An instance of this class with the fields populated, if present.