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

# List billing transactions

> Page through billing transactions and sort the results.



## OpenAPI

````yaml api-reference/billing/openapi.json GET /v1/billing/transactions
openapi: 3.0.3
info:
  title: Persistence Billing API
  version: '1.0'
  description: View Persistence billing transactions.
servers:
  - url: https://api.persistence.dev
    description: Production
security:
  - ApiKeyAuth: []
tags:
  - name: Billing
    description: Billing transaction history.
paths:
  /v1/billing/transactions:
    get:
      tags:
        - Billing
      summary: List billing transactions
      description: List billing transactions with pagination and sorting.
      operationId: listBillingTransactions
      parameters:
        - name: page
          in: query
          required: false
          description: Page number
          schema:
            type: integer
        - name: perPage
          in: query
          required: false
          description: Items per page
          schema:
            type: integer
        - name: column
          in: query
          required: false
          description: Sort column
          schema:
            type: string
            enum:
              - created_at
              - amount
              - status
              - type
              - category
        - name: order
          in: query
          required: false
          description: Sort order
          schema:
            $ref: '#/components/schemas/SortOrder'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TransactionListResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  schemas:
    SortOrder:
      type: string
      enum:
        - asc
        - desc
    TransactionListResponse:
      type: object
      properties:
        column:
          type: string
        items:
          type: array
          items:
            $ref: '#/components/schemas/Transaction'
        order:
          $ref: '#/components/schemas/SortOrder'
        page:
          type: integer
        perPage:
          type: integer
        searchText:
          type: string
        totalCount:
          type: integer
    Transaction:
      type: object
      properties:
        amount:
          type: integer
        category:
          $ref: '#/components/schemas/TransactionCategory'
        createdAt:
          type: string
        id:
          type: string
        invoice:
          type: string
        lastAttemptedAt:
          type: string
        lineItems:
          type: array
          items:
            $ref: '#/components/schemas/TransactionLineItem'
        metadata:
          type: object
          additionalProperties: true
        status:
          $ref: '#/components/schemas/TransactionStatus'
        type:
          $ref: '#/components/schemas/TransactionType'
        updatedAt:
          type: string
    Error:
      type: object
      properties:
        code:
          type: string
        details:
          type: array
          items:
            type: object
            additionalProperties: true
        error:
          type: string
    TransactionCategory:
      type: string
      enum:
        - purchase
        - subscription
        - usage
        - charge
        - refund
        - adjustment
        - trial_credit
    TransactionLineItem:
      type: object
      properties:
        amount:
          type: integer
        id:
          type: integer
        metadata:
          type: string
        provider:
          type: string
        quantity:
          type: integer
        transactionId:
          type: integer
        type:
          type: string
        unit:
          type: string
        unitPrice:
          type: integer
    TransactionStatus:
      type: string
      enum:
        - pending
        - pending_payment
        - processing
        - paid
        - succeeded
        - failed
        - refunded
    TransactionType:
      type: string
      enum:
        - debit
        - credit
  responses:
    BadRequest:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unauthorized:
      description: Unauthorized
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Forbidden:
      description: Forbidden
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: Not Found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-Key

````