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

# Get Accrual



## OpenAPI

````yaml https://app.usequanta.com/openapi/quanta-services-api/openapi.json get /api/alpha/accruals/{accrual_qid}
openapi: 3.1.0
info:
  title: FastAPI
  version: 0.1.0
servers:
  - url: https://app.usequanta.com
    description: Production
security:
  - HTTPBearer: []
paths:
  /api/alpha/accruals/{accrual_qid}:
    get:
      tags:
        - accruals
        - quanta-services-api
      summary: Get Accrual
      operationId: get_accrual
      parameters:
        - name: accrual_qid
          in: path
          required: true
          schema:
            type: string
            title: Accrual Qid
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetAccrualResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBearer: []
components:
  schemas:
    GetAccrualResponse:
      properties:
        ledger_view:
          $ref: '#/components/schemas/AccrualLedgerView'
      type: object
      required:
        - ledger_view
      title: GetAccrualResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    AccrualLedgerView:
      properties:
        events:
          items:
            $ref: '#/components/schemas/OperationalEvent'
          type: array
          title: Events
        accrual:
          $ref: '#/components/schemas/Accrual'
        journal_entry:
          $ref: '#/components/schemas/JournalEntry'
        balance_transactions:
          items:
            $ref: '#/components/schemas/BalanceTransaction'
          type: array
          minItems: 1
          title: Balance Transactions
        open_amount:
          $ref: '#/components/schemas/MonetaryAmount-Output'
          readOnly: true
        is_open:
          type: boolean
          title: Is Open
          readOnly: true
      type: object
      required:
        - events
        - accrual
        - journal_entry
        - balance_transactions
        - open_amount
        - is_open
      title: AccrualLedgerView
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
    OperationalEvent:
      properties:
        qid:
          type: string
          title: Qid
        org_qid:
          type: string
          title: Org Qid
        group_qid:
          type: string
          title: Group Qid
        origin_type:
          anyOf:
            - $ref: '#/components/schemas/OperationalEventOriginType'
            - type: 'null'
        origin_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Origin Qid
        payload:
          $ref: '#/components/schemas/OperationalEventBaseModel'
        idempotency_key:
          type: string
          title: Idempotency Key
      type: object
      required:
        - qid
        - org_qid
        - group_qid
        - payload
        - idempotency_key
      title: OperationalEvent
    Accrual:
      properties:
        qid:
          type: string
          title: Qid
        org_qid:
          type: string
          title: Org Qid
        amount:
          $ref: '#/components/schemas/MonetaryAmount-Output'
        effective_date:
          type: string
          format: date
          title: Effective Date
        description:
          type: string
          title: Description
      type: object
      required:
        - qid
        - org_qid
        - amount
        - effective_date
        - description
      title: Accrual
    JournalEntry:
      properties:
        qid:
          type: string
          title: Qid
        org_qid:
          type: string
          title: Org Qid
        effective_date:
          type: string
          format: date
          title: Effective Date
        line_items:
          items:
            $ref: '#/components/schemas/JournalEntryLineItem'
          type: array
          title: Line Items
        source_qid:
          type: string
          title: Source Qid
        source:
          $ref: '#/components/schemas/Source'
        operational_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Operational Qid
        event_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Event Qid
        entity_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Entity Qid
        audit_links:
          items:
            $ref: '#/components/schemas/JournalEntryAuditLink'
          type: array
          title: Audit Links
      type: object
      required:
        - qid
        - org_qid
        - effective_date
        - line_items
        - source_qid
        - source
      title: JournalEntry
    BalanceTransaction:
      properties:
        qid:
          type: string
          title: Qid
        org_qid:
          type: string
          title: Org Qid
        transaction_qid:
          type: string
          title: Transaction Qid
        account_qid:
          type: string
          title: Account Qid
        amount:
          $ref: '#/components/schemas/MonetaryAmount-Output'
        effective_date:
          type: string
          format: date
          title: Effective Date
        reversed_by:
          anyOf:
            - type: string
            - type: 'null'
          title: Reversed By
        event_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Event Qid
        event_type:
          anyOf:
            - $ref: '#/components/schemas/BalanceTransactionEventType'
            - type: 'null'
        matched_transaction_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Matched Transaction Qid
        matched_source_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Matched Source Qid
      type: object
      required:
        - qid
        - org_qid
        - transaction_qid
        - account_qid
        - amount
        - effective_date
      title: BalanceTransaction
    MonetaryAmount-Output:
      properties:
        amount:
          type: string
          pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
          title: Amount
        currency:
          $ref: '#/components/schemas/Currency'
      type: object
      required:
        - amount
        - currency
      title: MonetaryAmount
      description: Immutable monetary value with currency.
    OperationalEventOriginType:
      type: string
      enum:
        - INGESTION_SYNC
        - API
        - AGENT_INPUT
      title: OperationalEventOriginType
    OperationalEventBaseModel:
      properties:
        event_type:
          $ref: '#/components/schemas/OperationalEventType'
      type: object
      required:
        - event_type
      title: OperationalEventBaseModel
    JournalEntryLineItem:
      properties:
        qid:
          type: string
          title: Qid
        account:
          $ref: '#/components/schemas/Account'
        amount:
          type: string
          pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
          title: Amount
        description:
          type: string
          title: Description
        metadata:
          anyOf:
            - $ref: '#/components/schemas/JournalEntryLineMetadata'
            - type: 'null'
        booking_item_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Booking Item Qid
        balance_transaction_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Balance Transaction Qid
        booking_item:
          anyOf:
            - $ref: '#/components/schemas/JournalEntryBookingItem'
            - type: 'null'
        currency:
          type: string
          title: Currency
          default: USD
      type: object
      required:
        - qid
        - account
        - amount
        - description
        - metadata
      title: JournalEntryLineItem
    Source:
      type: string
      enum:
        - quanta
        - amex
        - deel
        - qbo
        - ramp
        - ramp_bank
        - rippling
        - stripe
        - gusto
        - brex
        - frb
        - fidelity
        - justworks
        - sequoia_one
        - chase
        - wells_fargo_ceo
        - mercury
        - meow_bank
        - bank_of_america
        - svb
        - morgan_stanley
        - other_bank
        - other_finicity_bank
        - angellist_banking
        - arc
        - carta
        - manual
        - bank_upload
        - local_bank
        - card_upload
        - reimbursement_upload
        - warp
        - rho
        - stifel
        - highbeam
        - erebor
        - wise
        - td_canada
        - central_payroll
        - rillet
        - campfire
        - netsuite
        - orb
        - prepaid
        - loan
        - accrued_expense
        - pricing_component
        - invoice_sent
        - fixed_asset
        - intangible_asset
        - stripe_invoice
        - payment_event
        - month_end_event
        - out_of_band_invoice
        - derivative_payable
      title: Source
    JournalEntryAuditLink:
      properties:
        link_type:
          $ref: '#/components/schemas/JournalEntryLinkType'
        original_qid:
          type: string
          title: Original Qid
        edit_qid:
          type: string
          title: Edit Qid
      type: object
      required:
        - link_type
        - original_qid
        - edit_qid
      title: JournalEntryAuditLink
    BalanceTransactionEventType:
      anyOf:
        - $ref: '#/components/schemas/OperationalEventType'
        - $ref: '#/components/schemas/InvoiceLedgerEventType'
    Currency:
      type: string
      enum:
        - AED
        - AFN
        - ALL
        - AMD
        - ANG
        - AOA
        - ARS
        - AUD
        - AWG
        - AZN
        - BAM
        - BBD
        - BDT
        - BGN
        - BHD
        - BIF
        - BMD
        - BND
        - BOB
        - BOV
        - BRL
        - BSD
        - BTN
        - BWP
        - BYN
        - BZD
        - CAD
        - CDF
        - CHE
        - CHF
        - CHW
        - CLF
        - CLP
        - CNY
        - COP
        - COU
        - CRC
        - CUC
        - CUP
        - CVE
        - CZK
        - DJF
        - DKK
        - DOP
        - DZD
        - EGP
        - ERN
        - ETB
        - EUR
        - FJD
        - FKP
        - GBP
        - GEL
        - GHS
        - GIP
        - GMD
        - GNF
        - GTQ
        - GYD
        - HKD
        - HNL
        - HTG
        - HUF
        - IDR
        - ILS
        - INR
        - IQD
        - IRR
        - ISK
        - JMD
        - JOD
        - JPY
        - KES
        - KGS
        - KHR
        - KMF
        - KPW
        - KRW
        - KWD
        - KYD
        - KZT
        - LAK
        - LBP
        - LKR
        - LRD
        - LSL
        - LYD
        - MAD
        - MDL
        - MGA
        - MKD
        - MMK
        - MNT
        - MOP
        - MRU
        - MUR
        - MVR
        - MWK
        - MXN
        - MXV
        - MYR
        - MZN
        - NAD
        - NGN
        - NIO
        - NOK
        - NPR
        - NZD
        - OMR
        - PAB
        - PEN
        - PGK
        - PHP
        - PKR
        - PLN
        - PYG
        - QAR
        - RON
        - RSD
        - RUB
        - RWF
        - SAR
        - SBD
        - SCR
        - SDG
        - SEK
        - SGD
        - SHP
        - SLE
        - SLL
        - SOS
        - SRD
        - SSP
        - STN
        - SVC
        - SYP
        - SZL
        - THB
        - TJS
        - TMT
        - TND
        - TOP
        - TRY
        - TTD
        - TWD
        - TZS
        - UAH
        - UGX
        - USD
        - USN
        - UYI
        - UYU
        - UYW
        - UZS
        - VED
        - VES
        - VND
        - VUV
        - WST
        - XAF
        - XCD
        - XDR
        - XOF
        - XPF
        - XSU
        - XUA
        - YER
        - ZAR
        - ZMW
        - ZWL
      title: Currency
    OperationalEventType:
      type: string
      enum:
        - BILLPAY_CREATE
        - BILLPAY_AMEND
        - BILLPAY_ARCHIVE
        - BILLPAY_MEMO_CREATE
        - BOOKING_UPDATE
        - REIMBURSEMENT_CREATE
        - REIMBURSEMENT_AMEND
        - REIMBURSEMENT_ARCHIVE
        - REIMBURSEMENT_MEMO_CREATE
        - ACCRUAL_CREATE
        - ACCOUNT_CREATE
        - ACCOUNT_AMEND
        - ACCOUNT_ARCHIVE
      title: OperationalEventType
    Account:
      properties:
        org_qid:
          type: string
          title: Org Qid
        qid:
          type: string
          title: Qid
        name:
          type: string
          title: Name
        type:
          $ref: '#/components/schemas/AccountType'
        lookup_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Lookup Id
        overrides:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Overrides
        is_leaf_account:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Leaf Account
        booking_disabled_on:
          anyOf:
            - type: string
              format: date
            - type: 'null'
          title: Booking Disabled On
        number:
          anyOf:
            - type: string
            - type: 'null'
          title: Number
      type: object
      required:
        - org_qid
        - qid
        - name
        - type
      title: Account
    JournalEntryLineMetadata:
      properties:
        department_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Department Qid
        spend_trait_vendor_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Spend Trait Vendor Qid
        customer_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Customer Qid
        product_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Product Qid
        department_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Department Name
        spend_trait_vendor_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Spend Trait Vendor Name
        spend_trait_vendor_logo_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Spend Trait Vendor Logo Url
        customer_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Customer Name
        customer_logo_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Customer Logo Url
        product_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Product Name
      type: object
      required:
        - department_qid
        - spend_trait_vendor_qid
        - customer_qid
        - product_qid
      title: JournalEntryLineMetadata
    JournalEntryBookingItem:
      properties:
        qid:
          type: string
          title: Qid
        gl_account:
          anyOf:
            - $ref: '#/components/schemas/Account'
            - type: 'null'
        vendor_qid:
          anyOf:
            - type: string
            - type: 'null'
          title: Vendor Qid
        vendor_name:
          anyOf:
            - type: string
            - type: 'null'
          title: Vendor Name
        vendor_logo_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Vendor Logo Url
      type: object
      required:
        - qid
        - gl_account
      title: JournalEntryBookingItem
    JournalEntryLinkType:
      type: string
      enum:
        - edit
        - reversal
      title: JournalEntryLinkType
    InvoiceLedgerEventType:
      type: string
      enum:
        - credit_note_created
        - credit_note_updated
        - credit_note_voided
        - customer_credit_applied
        - customer_credit_application_reversed
        - dispute_created
        - dispute_reversal_created
        - invoice_created
        - invoice_uncollectible
        - invoice_voided
        - payment_created
        - payment_reversed
        - payment_failure_refund_created
        - refund_created
        - refund_failure_created
        - booking_updated
        - schedule_items_updated
        - service_period_updated
        - invoice_metadata_updated
      title: InvoiceLedgerEventType
    AccountType:
      type: string
      enum:
        - ACCOUNTS_RECEIVABLE
        - BANK
        - FIXED_ASSET
        - OTHER_ASSET
        - OTHER_CURRENT_ASSET
        - ACCOUNTS_PAYABLE
        - CREDIT_CARD
        - OTHER_CURRENT_LIABILITY
        - LONG_TERM_LIABILITY
        - EQUITY
        - INCOME
        - OTHER_INCOME
        - COST_OF_GOODS_SOLD
        - EXPENSE
        - OTHER_EXPENSE
      title: AccountType
  securitySchemes:
    HTTPBearer:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Quanta Services API scoped bearer token. Supported only on Services API
        routes.

````

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