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

# Get transaction aggregations

> Get transaction aggregations



## OpenAPI

````yaml get /transaction/aggregation
openapi: 3.1.0
info:
  title: Slash Public API
  description: API description
  version: 0.0.1
  contact: {}
servers:
  - url: https://api.slash.com
    description: production
security:
  - api_key: []
  - partner_api_key: []
  - bearer: []
  - developer_application: []
paths:
  /transaction/aggregation:
    get:
      description: Get transaction aggregations
      parameters:
        - name: accountId
          deprecated: true
          description: Use filter:accountId to filter by account ID
          in: query
          schema:
            type: string
          required: false
        - name: filter:legalEntityId
          in: query
          description: >-
            Pass in a legal entity ID to filter transactions by accounts under a
            specific legal entity.
          required: false
          schema:
            type: string
        - name: filter:accountId
          description: >-
            Pass in an account ID to filter transactions by account ID. This
            will return all transactions that match the account ID passed in.
          in: query
          schema:
            type: string
          required: false
        - name: filter:virtualAccountId
          description: >-
            Pass in a virtual account ID to filter transactions by virtual
            account ID. This will return all transactions that match the virtual
            account ID passed in.
          in: query
          schema:
            type: string
          required: false
        - name: filter:from_date
          description: >-
            Pass in a unix timestamp in milliseconds to filter transactions by
            date. This will return all transactions that occurred on or after
            the date passed in.
          in: query
          schema:
            type: string
          required: false
        - name: filter:to_date
          description: >-
            Pass in a unix timestamp in milliseconds to filter transactions by
            date. This will return all transactions that occurred on or before
            the date passed in.
          in: query
          schema:
            type: string
          required: false
        - name: filter:from_authorized_at
          description: >-
            Pass in a unix timestamp in milliseconds to filter transactions by
            authorization time. This will return all transactions that are
            authorized on or after the date passed in.
          in: query
          schema:
            type: string
          required: false
        - name: filter:to_authorized_at
          description: >-
            Pass in a unix timestamp in milliseconds to filter transactions by
            authorization time. This will return all transactions that are
            authorized on or before the date passed in.
          in: query
          schema:
            type: string
          required: false
        - name: filter:status
          description: Filter transactions by status
          in: query
          schema:
            type: string
            description: >
              `pending` - The transaction is pending and has not been posted to
              the account yet (the balance doesn't reflect the transaction yet).

              `posted` - The transaction has been posted to the account and the
              balance reflects the transaction.

              `failed` - The transaction failed to post to the account
            enum:
              - pending
              - posted
              - failed
        - name: filter:detailed_status
          description: Filter transactions by detailed status
          in: query
          schema:
            type: string
            description: >
              - `pending`: Used for any transaction type that has not posted to
              the account yet, but is affecting the account's available balance.

              - `canceled`: Used for any transaction that was canceled.

              - `failed`: Used for any transaction that failed to post to the
              account.

              - `settled`: Used for any transaction that has posted to the
              account, except for card refunds, which use the `refund` status,
              and ACH returns, which use the `returned` status.

              - `declined`: Used for card transactions that were declined.

              - `refund`: Used for card transactions that were refunded,
              increasing the account's available and posted balances.

              - `reversed`: Used for card transactions that were authorized, but
              reversed by the merchant.

              - `returned`: Used for ACH returns. In the case of an ACH return,
              there are two possibilities: (1) if the ACH settled and then
              returned, then there will be one transaction with status `settled`
              for the ACH settling, and one transaction with status `returned`
              for the ACH return. Both of these are posted transactions. (2) if
              the ACH returned before settling, then there will only be one
              transaction with status `canceled`.

              - `dispute`: Used for disputed card transactions.
            enum:
              - pending
              - canceled
              - failed
              - settled
              - declined
              - refund
              - reversed
              - returned
              - dispute
        - name: filter:cardId
          description: Filter transactions by cardId
          in: query
          schema:
            type: string
          required: false
        - name: filter:category
          description: Filter transactions by category type
          in: query
          schema:
            type: string
            description: >
              Filter by transaction category:

              - `card`: Card transactions (authorizations, purchases, refunds)

              - `ach`: ACH transfers (credits and debits)

              - `wire`: Domestic wire transfers

              - `international_wire`: International wire transfers

              - `rtp`: Real-time payments

              - `fee`: Fees (card fees, transfer fees, subscription fees)

              - `internal`: Internal transfers (between accounts, treasury
              transfers)
            enum:
              - card
              - ach
              - wire
              - international_wire
              - rtp
              - fee
              - internal
          required: false
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  count:
                    type: number
                    description: The total count of transactions.
                  totalIn:
                    type: number
                    description: >-
                      The total amount of money that arrived into the account,
                      in cents.
                  totalOut:
                    type: number
                    description: >-
                      The total amount of money that was sent out of the
                      account, in cents.
                  netChange:
                    type: number
                    description: The net change, which is `totalIn` + `totalOut`.
                required:
                  - count
                  - totalIn
                  - totalOut
                  - netChange
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: TooManyRequests
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '500':
          description: Internal Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - api_key: []
        - bearer: []
components:
  schemas:
    Error:
      type: object
      properties:
        message:
          type: string
        name:
          type: string
        identifier:
          type: string
        rawStatus:
          type: number
        meta:
          type: object
          additionalProperties: true
      required:
        - message
        - name
        - identifier
        - rawStatus
      x-entrypoint:
        origin: ./src/publicApi
        sourcePath: ./src/publicApi/main.yaml
        title: Error
        virtualPath: components/Error
      title: Error
  securitySchemes:
    api_key:
      type: apiKey
      description: |
        API key authentication for public API requests.

        Keys come in two flavors:

        - *Legal-entity-scoped keys* are pinned to a single legal entity.
          Minted via the dashboard under a specific entity; every request
          acts on that entity.
        - *User-scoped keys* are pinned to a user and span every legal
          entity that user has access to. Every request made with a
          user-scoped key (except `GET /legal-entity`, which lists the
          legal entities the user can access) must include an
          `x-legal-entity` header naming the legal entity the request is
          operating on. Requests without the header are rejected with
          `400`. The authenticated user must have an active permission
          role on the supplied legal entity, otherwise the request is
          rejected with `403`.
      name: X-API-Key
      in: header
    partner_api_key:
      type: apiKey
      description: |
        Partner-program API key authentication.

        Keys are minted in the partner dashboard (Developers → API Keys),
        are scoped to a single partner program, and are prefixed with
        `sk_partner_`. Partner keys are only accepted by routes that
        declare this scheme; they are rejected by `api_key` routes and
        vice versa.
      name: X-API-Key
      in: header
    bearer:
      type: http
      scheme: bearer
    developer_application:
      type: http
      scheme: basic

````