{
  "data": {
    "type": "Custom_Journal_Entry",
    "id": "c635d706-bf18-41a1-b4ea-83a4768b6e14",
    "business_id": "188eb399-f171-4849-861c-5c02d91f800b",
    "external_id": "journal-entry-1",
    "created_by": "user-123",
    "memo": "Q1 Adjustment for Deferred Revenue",
    "entry_id": "695f6e4f-ddbb-4930-98cc-6496cd719a11",
    "customer": {
      "id": "a4c38874-8c01-4986-b8d0-4f159a52dd39",
      "external_id": "customer-1",
      "individual_name": null,
      "company_name": "Acme Corp",
      "email": "billing@acme.com",
      "mobile_phone": null,
      "office_phone": null,
      "address_string": null,
      "notes": null,
      "status": "ACTIVE"
    },
    "vendor": null,
    "line_items": [
      {
        "id": "733de30f-db72-4d52-98c5-fe070d4433f7",
        "external_id": "journal-line-item-1",
        "memo": "Deferred revenue recognition",
        "account_identifier": {
          "type": "AccountId",
          "id": "80b708b5-7b27-456c-9fb1-b8b918241908"
        },
        "amount": 100000,
        "direction": "DEBIT",
        "line_item_id": "ledger-line-item-789"
      },
      {
        "id": "854fe31f-ec73-5e63-09d6-gf171e5544g8",
        "external_id": "journal-line-item-2",
        "memo": "Revenue recognition",
        "account_identifier": {
          "type": "AccountId",
          "id": "90c819c6-8c38-567d-0gb2-c9c029352a19"
        },
        "amount": 100000,
        "direction": "CREDIT",
        "line_item_id": "ledger-line-item-790"
      }
    ],
    "entry": {
          "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "business_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "ledger_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "agent": "API",
          "entry_type": "BANK",
          "date": "2023-11-07T05:31:56Z",
          "entry_at": "2023-11-07T05:31:56Z",
          "reversal_of_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "reversal_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "line_items": [
            {
              "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
              "entry_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
              "account": {
                "id": {
                  "type": "AccountId",
                  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
                },
                "name": "Current Assets",
                "stable_name": {
                  "type": "StableName",
                  "stable_name": "CURRENT_ASSETS"
                },
                "normality": "CREDIT",
                "account_type": {
                  "value": "ASSET",
                  "display_name": "Asset"
                },
                "account_subtype": {
                  "value": "CURRENT",
                  "display_name": "Current Assets"
                }
              },
              "amount": 123,
              "direction": "CREDIT",
              "entry_at": "2023-11-07T05:31:56Z",
              "createdAt": "2023-11-07T05:31:56Z"
            }
          ]
        },
    "transaction_tags": [
      {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "key": "Department",
        "value": "Finance",
        "created_at": "2023-11-07T05:31:56Z",
        "updated_at": "2023-11-07T05:31:56Z",
        "deleted_at": null
      }
    ]
  }
}
A Custom Journal Entry represents a journal entry that is manually created by your system to reflect an accounting activity. Custom Journal Entries can be used to reflect any kind of accounting activity that isn’t reflected in Layer’s standard (Accounts Receivable / Accounts Payable / Bank Transactions / etc) workflows. Note that Custom Journal Entries contain metadata about a journal entry and are not journal entries in and of themselves.

Attributes

id
string
required
Unique identifier for the custom journal entry (the domain object, as opposed to the underlying ledger-layer journal entry).
type
string
required
Resource type. Value will be “Custom_Journal_Entry”.
external_id
string
Unique ID of the custom journal entry in your system for linking purposes and idempotency.
business_id
string
required
ID of the Business that generated the custom journal entry.
created_by
string
required
Identifier of the user or system that created the journal entry.
entry_id
string
required
ID of the underlying ledger entry.
customer
Customer object
The Customer Object associated with this journal entry, if any.
vendor
Vendor object
The Vendor Object associated with this journal entry, if any.
line_items
array of CustomJournalEntryLineItem objects
required
Line items making up the custom journal entry. Array of Custom Journal Entry Line Items comprising the Journal Entry.
entry
Journal Entry object
The Journal Entry Object associated with this Custom Journal Entry.
transaction_tags
Array of Tags
Tags associated with the custom journal entry.
memo
string
Memo for any text you would like to associate with the bill (for example, to display to end users).
metadata
object
Arbitrary custom metadata in JSON format with a size limit of 10KB.
reference_number
string
Any (typically user-visible) identifier you would like to associate with the bill. Can be used to filter when listing bills.

Custom Journal Entry Line Item object

A domain-level object that stores additional metadata about one of the line items of the underlying journal entry
id
string
required
Unique identifier for the line item.
external_id
string
External ID of the line item in your system.
memo
string
Optional memo for the line item.
line_item_id
string
required
ID of the line item in the ledger.
{
  "data": {
    "type": "Custom_Journal_Entry",
    "id": "c635d706-bf18-41a1-b4ea-83a4768b6e14",
    "business_id": "188eb399-f171-4849-861c-5c02d91f800b",
    "external_id": "journal-entry-1",
    "created_by": "user-123",
    "memo": "Q1 Adjustment for Deferred Revenue",
    "entry_id": "695f6e4f-ddbb-4930-98cc-6496cd719a11",
    "customer": {
      "id": "a4c38874-8c01-4986-b8d0-4f159a52dd39",
      "external_id": "customer-1",
      "individual_name": null,
      "company_name": "Acme Corp",
      "email": "billing@acme.com",
      "mobile_phone": null,
      "office_phone": null,
      "address_string": null,
      "notes": null,
      "status": "ACTIVE"
    },
    "vendor": null,
    "line_items": [
      {
        "id": "733de30f-db72-4d52-98c5-fe070d4433f7",
        "external_id": "journal-line-item-1",
        "memo": "Deferred revenue recognition",
        "account_identifier": {
          "type": "AccountId",
          "id": "80b708b5-7b27-456c-9fb1-b8b918241908"
        },
        "amount": 100000,
        "direction": "DEBIT",
        "line_item_id": "ledger-line-item-789"
      },
      {
        "id": "854fe31f-ec73-5e63-09d6-gf171e5544g8",
        "external_id": "journal-line-item-2",
        "memo": "Revenue recognition",
        "account_identifier": {
          "type": "AccountId",
          "id": "90c819c6-8c38-567d-0gb2-c9c029352a19"
        },
        "amount": 100000,
        "direction": "CREDIT",
        "line_item_id": "ledger-line-item-790"
      }
    ],
    "entry": {
          "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "business_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "ledger_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "agent": "API",
          "entry_type": "BANK",
          "date": "2023-11-07T05:31:56Z",
          "entry_at": "2023-11-07T05:31:56Z",
          "reversal_of_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "reversal_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
          "line_items": [
            {
              "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
              "entry_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
              "account": {
                "id": {
                  "type": "AccountId",
                  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
                },
                "name": "Current Assets",
                "stable_name": {
                  "type": "StableName",
                  "stable_name": "CURRENT_ASSETS"
                },
                "normality": "CREDIT",
                "account_type": {
                  "value": "ASSET",
                  "display_name": "Asset"
                },
                "account_subtype": {
                  "value": "CURRENT",
                  "display_name": "Current Assets"
                }
              },
              "amount": 123,
              "direction": "CREDIT",
              "entry_at": "2023-11-07T05:31:56Z",
              "createdAt": "2023-11-07T05:31:56Z"
            }
          ]
        },
    "transaction_tags": [
      {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "key": "Department",
        "value": "Finance",
        "created_at": "2023-11-07T05:31:56Z",
        "updated_at": "2023-11-07T05:31:56Z",
        "deleted_at": null
      }
    ]
  }
}