Development Guides

Set Aside Cash – Account Level

Setaside cash is used by eclipse to protect cash. The eclipse trade tools will remove the specified cash according to the setaside setup, and will not trade it unless the account is manually traded.

The dashboard will show “Cash Needs” where if there is a shortage of cash, the account can be rebalanced to raise cash.

This is useful for things like

  • One type distributions
  • Systematic distributions
  • Dollar cost averaging

Getting a list of setaside cash records for an account.

GET
https://test.orioneclipse.com/v1/account/accounts/<eclipseAccountId>/asidecash
propertydescriptionrequireddatatype
<eclipseAccountId>Eclipse Account IDYesInteger

Sample Response

[
    {
        "id": 484,
        "description": "One time distribution - client request (test)",
        "cashAmountTypeId": 1,
        "cashAmountTypeName": "$",
        "cashAmount": 1234,
        "expirationTypeId": 2,
        "expirationTypeName": "Transaction",
        "expirationValue": "Distribution / Merge Out",
        "toleranceValue": 20,
        "expiredOn": null,
        "isExpired": false,
        "portfolioSetAsideCashId": null,
        "setAsideAccountTypeName": "None",
        "isSystematic": false,
        "startDate": "2023-09-06T00:00:00.000Z",
        "isActive": true,
        "isBilling": false,
        "isDeleted": 0,
        "createdOn": "2023-09-06T16:38:05.000Z",
        "createdBy": null,
        "editedOn": "2023-09-06T18:16:33.000Z",
        "editedBy": null,
        "minCashAmount": null,
        "maxCashAmount": null,
        "percentCalculationTypeId": 0,
        "percentCalculationType": "Use Default/Managed Value"
    }
]

Create a new setaside cash record on an account

POST

https://test.orioneclipse.com/v1/account/accounts/<eclipseAccountId>/asidecash

propertydescriptionrequireddatatype
<eclipseAccountId>Eclipse Account IDYesInteger

BODY

propertydescriptionrequireddatatype
expirationTypeIdHow should this setaside cash expire? 1=Date 2=Transaction 3=NoneYes Default=2Integer
expirationValueWhen expirationTypeId is set to transaction, is the expiring transactioin of type distribution or of type fee? 1=Distribution/MergeOut 3=FeeWhen expirationTyeId=Transaction (2). Default=1Integer
setAsideAccountTypeId1=Contribution 2=Distribution 3=ro-rated based on Contribution % 4=Pro-rated based on Distribution %Yes Default=2Integer
cashAmountTypeIdWhen cashAmountTypeId=2 (%), this indicates which value to take a % of. 0=Managed Value 1=Total Value 2=Excluded ValueYes, Default=0Integer
cashAmount$ or % amount of cash to be protected.YesDecimal
toleranceValue% of tolerance when using a transaction to expire setaside.Required when experationTypeId=Transaction(2)Decimal
descriptionUp to 255 characters user description.NoString
startDateDate to start protecting cash.Yes, Default=TodayDate
minCashAmountMinimum Tolerance to allow protected cash to go.

When no value is entered, the minimum is the full setaside cashAmount.
NoDecimal
maxCashAmountMaximum Tolerance to allow protected cash to go.

When no value is entered, the maximum is the full setaside cashAmount.
NoDecimal
maxMultiplierNoInteger

Sample Body

{
    "expirationTypeId": 2,
    "expirationValue": 1,
    "setAsideAccountTypeId": 2,
    "cashAmountTypeId": 1,
    "percentCalculationTypeId": 0,
    "cashAmount": 6000,
    "toleranceValue": 20,
    "description": "One time distribution - client request (test)",
    "minCashAmount": null,
    "minMultiplier": null,
    "maxCashAmount": null,
    "maxMultiplier": null,
    "startDate": "2023-09-06"
}

Delete* Setaside Cash Record

DELETE

https://test.orioneclipse.com/v1/account/accounts/<eclipseAccountId>/asidecash/<setasideId>

*Note: Deleting will remove the record from the UI, if you want to keep it visible in the UI you should simply update the set aside cash record with an end date to expire it.


Create a DCA via API

To setup a DCA through the API, you will need to make multiple calls to the Add Set Aside endpoint, https://www.orioneclipse.com/v1/account/accounts/<eclipseAccountId>/asidecash, using a different expiration value. Below is an example.

Request 1:

{

“id”: 0,

“modified”: true,

“cashAmount”: 500,

“cashAmountTypeId”: 1,

“cashAmountTypeName”: “$”,

“description”: “”,

“expirationTypeId”: 1,

“expirationTypeName”: “Date”,

“expirationValue”: “2024-09-03”,

“maxCashAmount”: 500,

“minCashAmount”: 500,

“setAsideAccountTypeId”: 1,

“startDate”: “2024-09-03”,

“percentCalculationTypeId”: 0,

“setAsideAccountTypeName”: “Contribution”,

“percentCalculationType”: “Use Default/Managed Value”

}

Request 2 (the expirationValue will be the only thing that is different):

{

“id”: 0,

“modified”: true,

“cashAmount”: 500,

“cashAmountTypeId”: 1,

“cashAmountTypeName”: “$”,

“description”: “”,

“expirationTypeId”: 1,

“expirationTypeName”: “Date”,

“expirationValue”: “2024-09-10”,

“maxCashAmount”: 500,

“minCashAmount”: 500,

“setAsideAccountTypeId”: 1,

“startDate”: “2024-09-03”,

“percentCalculationTypeId”: 0,

“setAsideAccountTypeName”: “Contribution”,

“percentCalculationType”: “Use Default/Managed Value”

}