> ## Documentation Index
> Fetch the complete documentation index at: https://docs.plurex.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Stream account transactions

> New balance postings on the account (fees, funding payments, deposits and so on), each with the same ID ListTransactions returns. Reconcile with ListTransactions. Transaction events are ordered only among themselves, not relative to order events. Supported when the host's accountTransactions.subscribeToAccountTransactions is.



## AsyncAPI

````yaml api-reference/platform/plurex-platform-async-api.yaml hostsSubscribeToAccountTransactions
id: hostsSubscribeToAccountTransactions
title: Hosts subscribe to account transactions
description: ''
servers:
  - id: api
    protocol: wss
    host: api.plurex.io
    bindings: []
    variables: []
address: /api/v1/hosts/stream/SubscribeToAccountTransactions/{accountId}
parameters:
  - id: accountId
    jsonSchema:
      type: string
      description: The account to stream. Requires access to the account.
    description: The account to stream. Requires access to the account.
    type: string
    required: true
    deprecated: false
bindings: []
operations:
  - &ref_6
    id: hostsSubscribeToAccountTransactions
    title: Hosts subscribe to account transactions
    description: Stream account transactions
    type: send
    messages:
      - &ref_7
        id: AccountTransactionEnvelope
        contentType: application/json
        payload:
          - name: AccountTransactionEnvelope
            type: object
            properties:
              - name: timestamp
                type: string
                description: When Plurex sent the event.
                required: true
              - name: data
                type: object
                description: >-
                  One posting to an account balance, such as a fee, funding
                  payment or deposit. effectiveAt is when it took effect. Links
                  to orders, fills and positions are given only when the host
                  reports them. All fields are always present, null when empty.
                required: true
                properties:
                  - name: id
                    type: string
                    description: >-
                      Stable posting identifier within this account; identical
                      across history and stream.
                    required: true
                  - name: effectiveAt
                    type: string
                    required: true
                  - name: amount
                    type: object
                    required: true
                    properties:
                      - name: asset
                        type: string
                        required: true
                      - name: value
                        type: string
                        description: >-
                          An exact decimal number encoded as a string. No binary
                          floating-point rounding.
                        required: true
                  - name: type
                    type: string
                    enumValues:
                      - TradingFee
                      - FundingPayment
                      - BorrowInterest
                      - Financing
                      - LiquidationFee
                      - Settlement
                      - Rebate
                      - Deposit
                      - Withdrawal
                      - Transfer
                      - Conversion
                      - Adjustment
                      - Other
                    required: true
                  - name: instrument
                    type: anyOf
                    description: >-
                      Related instrument, or null when unknown or not
                      applicable.
                    required: true
                  - name: orderId
                    type: &ref_0
                      - string
                      - 'null'
                    description: Null when the host does not report it reliably.
                    required: true
                  - name: fillId
                    type: &ref_1
                      - string
                      - 'null'
                    description: Null when the host does not report it reliably.
                    required: true
                  - name: positionId
                    type: &ref_2
                      - string
                      - 'null'
                    description: Null when the host does not report it reliably.
                    required: true
                  - name: groupId
                    type: &ref_3
                      - string
                      - 'null'
                    description: Null when the host does not report it reliably.
                    required: true
                  - name: nativeType
                    type: &ref_4
                      - string
                      - 'null'
                    description: Null when the host does not report it reliably.
                    required: true
                  - name: description
                    type: &ref_5
                      - string
                      - 'null'
                    description: Null when the host does not report it reliably.
                    required: true
        headers: []
        jsonPayloadSchema:
          type: object
          required:
            - timestamp
            - data
          properties:
            timestamp:
              type: string
              format: date-time
              description: When Plurex sent the event.
              x-parser-schema-id: <anonymous-schema-89>
            data:
              type: object
              properties:
                id:
                  type: string
                  description: >-
                    Stable posting identifier within this account; identical
                    across history and stream.
                  x-parser-schema-id: <anonymous-schema-90>
                effectiveAt:
                  type: string
                  format: date-time
                  x-parser-schema-id: <anonymous-schema-91>
                amount:
                  type: object
                  properties:
                    asset:
                      type: string
                      x-parser-schema-id: <anonymous-schema-31>
                    value:
                      type: string
                      pattern: ^-?(?:0|[1-9][0-9]*)(?:\.[0-9]+)?(?:[eE][+-]?[0-9]+)?$
                      description: >-
                        An exact decimal number encoded as a string. No binary
                        floating-point rounding.
                      x-parser-schema-id: Decimal
                  required:
                    - asset
                    - value
                  x-parser-schema-id: AssetValue
                type:
                  type: string
                  enum:
                    - TradingFee
                    - FundingPayment
                    - BorrowInterest
                    - Financing
                    - LiquidationFee
                    - Settlement
                    - Rebate
                    - Deposit
                    - Withdrawal
                    - Transfer
                    - Conversion
                    - Adjustment
                    - Other
                  x-parser-schema-id: AccountTransactionType
                instrument:
                  anyOf:
                    - oneOf:
                        - type: object
                          properties:
                            base:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-7>
                            quote:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-8>
                            expiry:
                              type: string
                              format: date
                              description: Contract expiry date (YYYY-MM-DD).
                              x-parser-schema-id: <anonymous-schema-9>
                            type:
                              type: string
                              enum:
                                - Future
                              x-parser-schema-id: <anonymous-schema-10>
                          required:
                            - type
                            - base
                            - quote
                            - expiry
                          x-parser-schema-id: InstrumentFuture
                        - type: object
                          properties:
                            base:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-11>
                            quote:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-12>
                            expiry:
                              type: string
                              format: date
                              description: Contract expiry date (YYYY-MM-DD).
                              x-parser-schema-id: <anonymous-schema-13>
                            type:
                              type: string
                              enum:
                                - FutureInv
                              x-parser-schema-id: <anonymous-schema-14>
                          required:
                            - type
                            - base
                            - quote
                            - expiry
                          x-parser-schema-id: InstrumentFutureInv
                        - type: object
                          properties:
                            base:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-15>
                            quote:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-16>
                            expiry:
                              type: string
                              format: date
                              description: Contract expiry date (YYYY-MM-DD).
                              x-parser-schema-id: <anonymous-schema-17>
                            strike:
                              type: string
                              pattern: ^(?:0|[1-9][0-9]*)(?:\.[0-9]*[1-9])?$
                              description: >-
                                Positive strike price in the quote asset, in
                                canonical form so identity is exact; a plain
                                decimal with no exponent and no trailing
                                fractional zeros (50000, not 50000.0 or 5E4).
                              x-parser-schema-id: <anonymous-schema-18>
                            right:
                              type: string
                              enum:
                                - Call
                                - Put
                              x-parser-schema-id: OptionRight
                            type:
                              type: string
                              enum:
                                - Option
                              x-parser-schema-id: <anonymous-schema-19>
                          required:
                            - type
                            - base
                            - quote
                            - expiry
                            - strike
                            - right
                          description: >-
                            Option contract. Option markets are not listed or
                            tradable yet; options appear only where a host
                            reports account activity on them.
                          x-parser-schema-id: InstrumentOption
                        - type: object
                          properties:
                            base:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-20>
                            quote:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-21>
                            type:
                              type: string
                              enum:
                                - Perp
                              x-parser-schema-id: <anonymous-schema-22>
                          required:
                            - type
                            - base
                            - quote
                          x-parser-schema-id: InstrumentPerp
                        - type: object
                          properties:
                            base:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-23>
                            quote:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-24>
                            type:
                              type: string
                              enum:
                                - PerpInv
                              x-parser-schema-id: <anonymous-schema-25>
                          required:
                            - type
                            - base
                            - quote
                          x-parser-schema-id: InstrumentPerpInv
                        - type: object
                          properties:
                            base:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-26>
                            quote:
                              type: string
                              pattern: ^[A-Z0-9.]{1,32}$
                              x-parser-schema-id: <anonymous-schema-27>
                            type:
                              type: string
                              enum:
                                - Spot
                              x-parser-schema-id: <anonymous-schema-28>
                          required:
                            - type
                            - base
                            - quote
                          x-parser-schema-id: InstrumentSpot
                      description: >-
                        An instrument, identified by its fields rather than a
                        venue symbol: type, base, quote, and expiry, strike and
                        right where they apply. type takes the InstrumentType
                        values; unknown types are rejected. Market summaries
                        also give its canonical symbol.
                      x-parser-schema-id: Instrument
                    - type: 'null'
                      x-parser-schema-id: <anonymous-schema-93>
                  description: Related instrument, or null when unknown or not applicable.
                  x-parser-schema-id: <anonymous-schema-92>
                orderId:
                  type: *ref_0
                  description: Null when the host does not report it reliably.
                  x-parser-schema-id: <anonymous-schema-94>
                fillId:
                  type: *ref_1
                  description: Null when the host does not report it reliably.
                  x-parser-schema-id: <anonymous-schema-95>
                positionId:
                  type: *ref_2
                  description: Null when the host does not report it reliably.
                  x-parser-schema-id: <anonymous-schema-96>
                groupId:
                  type: *ref_3
                  description: Null when the host does not report it reliably.
                  x-parser-schema-id: <anonymous-schema-97>
                nativeType:
                  type: *ref_4
                  description: Null when the host does not report it reliably.
                  x-parser-schema-id: <anonymous-schema-98>
                description:
                  type: *ref_5
                  description: Null when the host does not report it reliably.
                  x-parser-schema-id: <anonymous-schema-99>
              required:
                - id
                - effectiveAt
                - amount
                - type
                - instrument
                - orderId
                - fillId
                - positionId
                - groupId
                - nativeType
                - description
              description: >-
                One posting to an account balance, such as a fee, funding
                payment or deposit. effectiveAt is when it took effect. Links to
                orders, fills and positions are given only when the host reports
                them. All fields are always present, null when empty.
              x-parser-schema-id: AccountTransaction
          x-parser-schema-id: StreamEnvelopeAccountTransaction
        title: Account transaction envelope
        example: No examples found
        bindings: []
        extensions:
          - id: x-parser-unique-object-id
            value: AccountTransactionEnvelope
    bindings: []
    extensions:
      - id: x-parser-unique-object-id
        value: hostsSubscribeToAccountTransactions
sendOperations: []
receiveOperations:
  - *ref_6
sendMessages: []
receiveMessages:
  - *ref_7
extensions:
  - id: x-parser-unique-object-id
    value: hostsSubscribeToAccountTransactions
securitySchemes:
  - id: ApiKeyPair
    name: X-API-KEY
    type: httpApiKey
    description: X-API-KEY and X-API-SECRET headers are both required.
    in: header
    extensions: []

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.