Transactions

Transactions are the ledger — every dated event that moves wealth. Holdings are reconstructed from them, performance is computed from them, and custodian reconciliation runs against them. The transaction model is typed per instrument class so that downstream consumers never have to guess what "price" or "quantity" mean on a given row.

Transaction types

Rather than one generic shape with nullable fields, each kind of event has its own transaction type. A few of the common ones:

  • Name
    AccountInterest
    Type
    cash
    Description

    Interest credited or debited on a cash balance. Carries the period the interest accrued over, the applicable rate, and the net amount booked.

  • Name
    BondTrade
    Type
    fixed income
    Description

    A buy or sell of a bond. Tracks clean and dirty price separately, accrued interest, and the settlement date distinct from the trade date.

  • Name
    BondCoupon
    Type
    fixed income
    Description

    Coupon payment on a bond. Links back to the trade it came from.

  • Name
    BondRedemption
    Type
    fixed income
    Description

    Principal repayment — partial call or final maturity.

  • Name
    EquityTrade
    Type
    equity
    Description

    A buy or sell of a listed equity. Includes execution price, fees, and the lot identity for SPECIFIC_ID accounting.

  • Name
    Dividend
    Type
    equity
    Description

    Cash or scrip dividend on an equity holding. Tracks gross, withholding, and net amounts separately.

  • Name
    FxTrade
    Type
    cash
    Description

    Currency conversion. Both legs with their rate and the implied cross.

  • Name
    Transfer
    Type
    flow
    Description

    A movement of assets between accounts — in-specie transfers, sub-account rebalancing. Flagged separately so performance attribution doesn't count it as return.

  • Name
    Fee
    Type
    flow
    Description

    Platform fees, custody fees, management fees. Categorised so reports can roll them up separately from investment returns.

More specialised types exist for private-market instruments (commitments, capital calls, distributions) and for derivative positions (margin calls, variation margin). The full list is exposed at the /v2/transaction-types endpoint; every type includes a JSON schema describing its payload.

Common fields

Every transaction type carries a shared prefix:

  • Name
    id
    Type
    string
    Description

    Stable identifier.

  • Name
    account_id
    Type
    string
    Description

    Account the transaction belongs to.

  • Name
    type
    Type
    string
    Description

    Tag telling consumers which typed shape to expect. Always present.

  • Name
    trade_date
    Type
    date
    Description

    When the event happened economically.

  • Name
    settlement_date
    Type
    date | null
    Description

    When cash or securities actually moved, if different from the trade date.

  • Name
    source
    Type
    enum
    Description

    custodian, manual, calculated. Tells you whether the row came from a feed, an upload, or a platform-side derivation.


POST/v2/transactions

Create a transaction

Books a manual transaction on an account. Pick the right type up front — the platform validates the payload against that type's schema and rejects the request if the shape doesn't match.

Manual transactions should only be booked when the custodian can't supply the event itself (uncustodied private assets, off-platform settlements). For anything that will arrive through a feed, let the feed deliver it — double-booking is how reconciliation bugs start.

Request

POST
/v2/transactions
curl -X POST https://api.aleta.io/v2/transactions \
  -H "Authorization: Bearer {token}" \
  -H "Content-Type: application/json" \
  -d '{
    "account_id": "acc_...",
    "type": "EquityTrade",
    "trade_date": "2026-03-14",
    "instrument_id": "inst_eq_dk_novo",
    "side": "buy",
    "quantity": 100,
    "price": 850.50,
    "fees": 15.00
  }'

DELETE/v2/transactions/{id}

Delete a transaction

Removes a transaction from the ledger and triggers an async rebuild of holdings and performance for every reporting entity the affected account rolls up into.

Subscribe to the calculated_data.created webhook to know when the rebuild has finished. Until the event fires, downstream holdings and performance queries may still return the pre-delete numbers.

Request

DELETE
/v2/transactions/{id}
curl -X DELETE https://api.aleta.io/v2/transactions/{id} \
  -H "Authorization: Bearer {token}"