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

# Update journal entry

## Field support per integration

<AccordionGroup>
  <Accordion title="Dinero" icon="https://mintcdn.com/maesn/kIVKlwzahCAaENRK/logo/dinero.svg?fit=max&auto=format&n=kIVKlwzahCAaENRK&q=85&s=5c26225da75d99a6f6e099c50483eaa3" width="200" height="200" data-path="logo/dinero.svg">
    <Note>
      If you're not using the [Interactive Authentication Flow](/authentication#interactive-authentication-flow), make sure the query parameter `companyId` is correctly populated.
    </Note>

    <Note>
      Only **provisional journal entries** (unbooked) can be updated.
    </Note>

    Supported request fields:

    <ResponseField name="journal_entry" type="string" required>
      <Expandable title="properties">
        <ResponseField name="isProvisional" type="boolean">
          Indicates whether the journal entry will be set as provisional (draft) or booked (finalized).

          If set to <code>true</code>, the journal entry remains `provisional` ; if set to <code>false</code>, the journal entry is booked.

          <Note>
            Defaults to <code>true</code> if not provided.
          </Note>
        </ResponseField>

        <ResponseField name="journalLineItems" type="JournalLineItem[]">
          <Note>
            If the journal line items are not provided, the existing line items associated with the journal entry will remain unchanged and will not be updated.
          </Note>

          <Expandable title="properties">
            <ResponseField name="id" type="string" required>
              Id for the journal line.
            </ResponseField>

            <ResponseField name="accountNumber" type="string" required>
              The account number. Must be numeric.

              When `documentId` is present, the `accountNumber` should be a bank account
            </ResponseField>

            <ResponseField name="description" type="string" required />

            <ResponseField name="debitCreditIndicator" type="enum" required>
              Available options: `DEBIT`, `CREDIT`
            </ResponseField>

            <ResponseField name="documentId" type="string">
              Reference to an invoice/bill ID for payment lines. When provided, the line becomes a **payment** that settles the referenced document.
            </ResponseField>

            <ResponseField name="totalNetAmount" type="number" required>
              The net amount for the line item. Must be a positive amount.
            </ResponseField>

            <ResponseField name="taxRate" type="taxRate">
              <Expandable title="properties">
                <ResponseField name="code" type="string">
                  VAT code for the account or contra-account.
                </ResponseField>
              </Expandable>
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="number" type="string">
          Journal entry number. Must be numeric.
        </ResponseField>

        <ResponseField name="transactionDate" type="string" required>
          For date format details visits the [`Standardized Data`](/standardization) section.

          It is the date the accounting entry is booked into the records.
        </ResponseField>

        <ResponseField name="version" type="string" required />
      </Expandable>
    </ResponseField>

    <ResponseField name="files" type="file[]" />
  </Accordion>
</AccordionGroup>


## OpenAPI

````yaml PUT /accounting/journalEntries/{journalEntryId}
openapi: 3.0.0
info:
  title: Maesn unified API
  description: The Maesn unified API description
  version: '1.0'
  contact: {}
servers:
  - url: https://api.maesn.dev
security: []
tags:
  - name: maesn
    description: ''
paths:
  /accounting/journalEntries/{journalEntryId}:
    put:
      tags:
        - accounting
      operationId: update JournalEntry
      parameters:
        - name: companyId
          required: false
          in: query
          schema:
            type: string
        - name: environmentName
          in: query
          schema:
            type: string
          required: false
        - name: journalEntryId
          required: true
          in: path
          schema:
            type: string
        - name: X-API-KEY
          description: API key
          in: header
          schema:
            type: string
            example: example value
          required: true
        - name: X-ACCOUNT-KEY
          description: Account key
          in: header
          schema:
            type: string
            example: example value
          required: true
      requestBody:
        required: true
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                files:
                  type: array
                  items:
                    format: binary
                  description: Array of files to upload
                filesPos:
                  type: array
                  items:
                    type: number
                  description: Array of file positions
                journal_entry:
                  $ref: '#/components/schemas/JournalentryRequestDto'
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/BaseResponseDto'
                  - properties:
                      data:
                        type: array
                        items:
                          $ref: '#/components/schemas/JournalentryResponseDto'
components:
  schemas:
    JournalentryRequestDto:
      type: object
      properties:
        accountId:
          type: string
          example: d1bfd23-517d-4ec6-b7d4-56f86c7cf246
        accountingPeriodId:
          type: string
          example: 2021-06
        accountingReason:
          type: string
          enum:
            - COMMERCIAL
            - TAX
            - IFRS
            - CALCULATION
            - INDEPENDENT
            - OTHER
          example: COMMERCIAL
        currency:
          type: string
          enum:
            - AED
            - AFN
            - ALL
            - AMD
            - ANG
            - AOA
            - ARS
            - AUD
            - AWG
            - AZN
            - BAM
            - BBD
            - BDT
            - BGN
            - BHD
            - BIF
            - BMD
            - BND
            - BOB
            - BRL
            - BSD
            - BTN
            - BWP
            - BYR
            - BZD
            - CAD
            - CDF
            - CHF
            - CLP
            - CNY
            - COP
            - CRC
            - CUC
            - CVE
            - CZK
            - DJF
            - DKK
            - DOP
            - DZD
            - EEK
            - EGP
            - ERN
            - ETB
            - EUR
            - FJD
            - FKP
            - GBP
            - GEL
            - GHS
            - GIP
            - GMD
            - GNF
            - GQE
            - GTQ
            - GYD
            - HKD
            - HNL
            - HRK
            - 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
            - LTL
            - LVL
            - LYD
            - MAD
            - MDL
            - MGA
            - MKD
            - MMK
            - MNT
            - MOP
            - MRO
            - MUR
            - MVR
            - MWK
            - MXN
            - MYR
            - MZM
            - NAD
            - NGN
            - NIO
            - NOK
            - NPR
            - NZD
            - OMR
            - PAB
            - PEN
            - PGK
            - PHP
            - PKR
            - PLN
            - PYG
            - QAR
            - RON
            - RSD
            - RUB
            - SAR
            - SBD
            - SCR
            - SDG
            - SEK
            - SGD
            - SHP
            - SLL
            - SOS
            - SRD
            - SYP
            - SZL
            - THB
            - TJS
            - TMT
            - TND
            - TRY
            - TTD
            - TWD
            - TZS
            - UAH
            - UGX
            - USD
            - UYU
            - UZS
            - VEB
            - VND
            - VUV
            - WST
            - XAF
            - XCD
            - XDR
            - XOF
            - XPF
            - YER
            - ZAR
            - ZMK
            - ZWR
          example: EUR
        description:
          type: string
          example: Hotel for dreamforce
        documentId:
          type: string
          example: b5e624e5-fb9e-4836-a443-87a3820f5b48
        isProvisional:
          type: boolean
          example: 'false'
        isReversal:
          type: boolean
          example: false
        journalLineItems:
          type: array
          items:
            $ref: '#/components/schemas/createJournalLineItem'
        journalCode:
          type: string
          example: '60'
        journalType:
          type: string
          example: FIN
        'number ':
          type: string
          example: '21900030'
        recordType:
          type: string
          enum:
            - STANDARD
            - CLOSING
            - OPENING
          example: STANDARD
        transactionDate:
          type: string
          example: '2021-01-01T00:00:00Z'
        version:
          type: string
          example: AAAAACnY3os1
    BaseResponseDto:
      type: object
      properties:
        meta:
          $ref: '#/components/schemas/MetaResponse'
        data:
          oneOf:
            - type: object
            - type: array
    JournalentryResponseDto:
      type: object
      properties:
        id:
          type: string
          example: 8df2df10-0fae-40ad-9d22-f25e5ab0ba23
        accountId:
          type: string
          example: 94fdb7fd-13ae-47a6-8a2a-000e6ddc60d9
        accountingPeriodId:
          type: string
          example: 2021-06
        accountingReason:
          type: string
          enum:
            - COMMERCIAL
            - TAX
            - IFRS
            - CALCULATION
            - INDEPENDENT
            - OTHER
          example: COMMERCIAL
        createdDate:
          type: string
          example: '2021-01-01T00:00:00Z'
        currency:
          type: string
          enum:
            - AED
            - AFN
            - ALL
            - AMD
            - ANG
            - AOA
            - ARS
            - AUD
            - AWG
            - AZN
            - BAM
            - BBD
            - BDT
            - BGN
            - BHD
            - BIF
            - BMD
            - BND
            - BOB
            - BRL
            - BSD
            - BTN
            - BWP
            - BYR
            - BZD
            - CAD
            - CDF
            - CHF
            - CLP
            - CNY
            - COP
            - CRC
            - CUC
            - CVE
            - CZK
            - DJF
            - DKK
            - DOP
            - DZD
            - EEK
            - EGP
            - ERN
            - ETB
            - EUR
            - FJD
            - FKP
            - GBP
            - GEL
            - GHS
            - GIP
            - GMD
            - GNF
            - GQE
            - GTQ
            - GYD
            - HKD
            - HNL
            - HRK
            - 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
            - LTL
            - LVL
            - LYD
            - MAD
            - MDL
            - MGA
            - MKD
            - MMK
            - MNT
            - MOP
            - MRO
            - MUR
            - MVR
            - MWK
            - MXN
            - MYR
            - MZM
            - NAD
            - NGN
            - NIO
            - NOK
            - NPR
            - NZD
            - OMR
            - PAB
            - PEN
            - PGK
            - PHP
            - PKR
            - PLN
            - PYG
            - QAR
            - RON
            - RSD
            - RUB
            - SAR
            - SBD
            - SCR
            - SDG
            - SEK
            - SGD
            - SHP
            - SLL
            - SOS
            - SRD
            - SYP
            - SZL
            - THB
            - TJS
            - TMT
            - TND
            - TRY
            - TTD
            - TWD
            - TZS
            - UAH
            - UGX
            - USD
            - UYU
            - UZS
            - VEB
            - VND
            - VUV
            - WST
            - XAF
            - XCD
            - XDR
            - XOF
            - XPF
            - YER
            - ZAR
            - ZMK
            - ZWR
          example: EUR
        description:
          type: string
          example: Hotel for dreamforce
        documentId:
          type: string
          example: b5e624e5-fb9e-4836-a443-87a3820f5b48
        files:
          type: array
          items:
            type: string
            example: file1.pdf
        isProvisional:
          type: boolean
          example: 'false'
        isReversal:
          type: boolean
          example: false
        journalLineItems:
          type: array
          items:
            $ref: '#/components/schemas/journalLineItem'
        journalCode:
          type: string
          example: '60'
        journalType:
          type: string
          example: FIN
        'number ':
          type: string
          example: '21900030'
        recordType:
          type: string
          enum:
            - STANDARD
            - CLOSING
            - OPENING
          example: STANDARD
        transactionDate:
          type: string
          example: '2021-01-01T00:00:00Z'
        updatedDate:
          type: string
          example: '2021-01-01T00:00:00Z'
        version:
          type: string
          example: AAAAACnY3os1
    createJournalLineItem:
      type: object
      properties:
        id:
          type: string
          example: 123f57fd-13ae-47a6-8a2a-000e6ddc60d9
        accountCode:
          type: string
          example: '4034'
        accountId:
          type: string
          example: 94fdb7fd-13ae-47a6-8a2a-000e6ddc60d9
        accountNumber:
          type: string
          example: '1200'
        currency:
          type: string
          enum:
            - AED
            - AFN
            - ALL
            - AMD
            - ANG
            - AOA
            - ARS
            - AUD
            - AWG
            - AZN
            - BAM
            - BBD
            - BDT
            - BGN
            - BHD
            - BIF
            - BMD
            - BND
            - BOB
            - BRL
            - BSD
            - BTN
            - BWP
            - BYR
            - BZD
            - CAD
            - CDF
            - CHF
            - CLP
            - CNY
            - COP
            - CRC
            - CUC
            - CVE
            - CZK
            - DJF
            - DKK
            - DOP
            - DZD
            - EEK
            - EGP
            - ERN
            - ETB
            - EUR
            - FJD
            - FKP
            - GBP
            - GEL
            - GHS
            - GIP
            - GMD
            - GNF
            - GQE
            - GTQ
            - GYD
            - HKD
            - HNL
            - HRK
            - 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
            - LTL
            - LVL
            - LYD
            - MAD
            - MDL
            - MGA
            - MKD
            - MMK
            - MNT
            - MOP
            - MRO
            - MUR
            - MVR
            - MWK
            - MXN
            - MYR
            - MZM
            - NAD
            - NGN
            - NIO
            - NOK
            - NPR
            - NZD
            - OMR
            - PAB
            - PEN
            - PGK
            - PHP
            - PKR
            - PLN
            - PYG
            - QAR
            - RON
            - RSD
            - RUB
            - SAR
            - SBD
            - SCR
            - SDG
            - SEK
            - SGD
            - SHP
            - SLL
            - SOS
            - SRD
            - SYP
            - SZL
            - THB
            - TJS
            - TMT
            - TND
            - TRY
            - TTD
            - TWD
            - TZS
            - UAH
            - UGX
            - USD
            - UYU
            - UZS
            - VEB
            - VND
            - VUV
            - WST
            - XAF
            - XCD
            - XDR
            - XOF
            - XPF
            - YER
            - ZAR
            - ZMK
            - ZWR
          example: EUR
        customerId:
          type: string
          example: 782d89b56-13ae-47a6-8a2a-45e6ddc50d9
        debitCreditIndicator:
          type: string
          enum:
            - DEBIT
            - CREDIT
          example: DEBIT
        description:
          type: string
          example: Uitgesteld 21600001 Kantoor 01-01-2021-31-12-2021
        dimensions:
          type: array
          items:
            $ref: '#/components/schemas/journalDimension'
        documentId:
          type: string
          example: b5e624e5-fb9e-4836-a443-87a3820f5b48
        documentNumber:
          type: string
          example: '123456789'
        exchangeRate:
          type: number
          example: 1
        supplierId:
          type: string
          example: 998933b56-13ae-47a6-8a32a-45e6ddc50d9
        taxRate:
          $ref: '#/components/schemas/taxRate'
          type: object
        thirdPartyCode:
          type: string
          example: '112233'
        totalGrossAmount:
          type: number
          example: 1190
        totalNetAmount:
          type: number
          example: 1000
        totalTaxAmount:
          type: number
          example: 190
    MetaResponse:
      type: object
      properties:
        warnings:
          type: array
          items:
            type: string
            example: Field not used by target system
        pagination:
          $ref: '#/components/schemas/PaginationResponse'
    journalLineItem:
      type: object
      properties:
        id:
          type: string
          example: 123f57fd-13ae-47a6-8a2a-000e6ddc60d9
        accountCode:
          type: string
          example: '4034'
        accountId:
          type: string
          example: da33b47c-98ca-4410-9c59-5db485ecaeb0
        accountNumber:
          type: number
          example: 8200
        'createdDate ':
          type: string
          example: '2021-01-01T00:00:00Z'
        currency:
          type: string
          enum:
            - AED
            - AFN
            - ALL
            - AMD
            - ANG
            - AOA
            - ARS
            - AUD
            - AWG
            - AZN
            - BAM
            - BBD
            - BDT
            - BGN
            - BHD
            - BIF
            - BMD
            - BND
            - BOB
            - BRL
            - BSD
            - BTN
            - BWP
            - BYR
            - BZD
            - CAD
            - CDF
            - CHF
            - CLP
            - CNY
            - COP
            - CRC
            - CUC
            - CVE
            - CZK
            - DJF
            - DKK
            - DOP
            - DZD
            - EEK
            - EGP
            - ERN
            - ETB
            - EUR
            - FJD
            - FKP
            - GBP
            - GEL
            - GHS
            - GIP
            - GMD
            - GNF
            - GQE
            - GTQ
            - GYD
            - HKD
            - HNL
            - HRK
            - 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
            - LTL
            - LVL
            - LYD
            - MAD
            - MDL
            - MGA
            - MKD
            - MMK
            - MNT
            - MOP
            - MRO
            - MUR
            - MVR
            - MWK
            - MXN
            - MYR
            - MZM
            - NAD
            - NGN
            - NIO
            - NOK
            - NPR
            - NZD
            - OMR
            - PAB
            - PEN
            - PGK
            - PHP
            - PKR
            - PLN
            - PYG
            - QAR
            - RON
            - RSD
            - RUB
            - SAR
            - SBD
            - SCR
            - SDG
            - SEK
            - SGD
            - SHP
            - SLL
            - SOS
            - SRD
            - SYP
            - SZL
            - THB
            - TJS
            - TMT
            - TND
            - TRY
            - TTD
            - TWD
            - TZS
            - UAH
            - UGX
            - USD
            - UYU
            - UZS
            - VEB
            - VND
            - VUV
            - WST
            - XAF
            - XCD
            - XDR
            - XOF
            - XPF
            - YER
            - ZAR
            - ZMK
            - ZWR
          example: EUR
        customerId:
          type: string
          example: 782d89b56-13ae-47a6-8a2a-45e6ddc50d9
        debitCreditIndicator:
          type: string
          enum:
            - DEBIT
            - CREDIT
          example: DEBIT
        description:
          type: string
          example: Uitgesteld 21600001 Kantoor 01-01-2021-31-12-2021
        dimensions:
          type: array
          items:
            $ref: '#/components/schemas/journalDimension'
        documentId:
          type: string
          example: b5e624e5-fb9e-4836-a443-87a3820f5b48
        documentNumber:
          type: string
          example: '123456789'
        exchangeRate:
          type: number
          example: 1
        supplierId:
          type: string
          example: 998933b56-13ae-47a6-8a32a-45e6ddc50d9
        taxRate:
          $ref: '#/components/schemas/taxRate'
          type: object
        thirdPartyCode:
          type: string
          example: '112233'
        totalGrossAmount:
          type: number
          example: 1190
        totalNetAmount:
          type: number
          example: 1000
        totalTaxAmount:
          type: number
          example: 190
        updatedDate:
          type: string
          example: '2021-01-01T00:00:00Z'
    journalDimension:
      type: object
      properties:
        id:
          type: string
          example: efa82f42-fd85-11e1-a21f-0800200c9a33
        categoryName:
          type: string
          example: CostCenter
        code:
          type: string
          example: KD1
        name:
          type: string
          example: Material/Waren
    taxRate:
      type: object
      properties:
        id:
          type: string
          example: 1895b05b-38a6-4a6a-9653-166389894350
        code:
          type: string
          example: '03'
        name:
          type: string
          example: Tax19
        taxRatePercentage:
          type: string
          example: '19'
    PaginationResponse:
      type: object
      properties:
        total:
          type: number
          example: 125
        perPage:
          type: number
          example: 50
        currentPage:
          type: number
          example: 1
        totalPages:
          type: number
          example: 3

````