Retrieve a journal entry
Changed onReturns a single journal entry of a Books instance by its journal entry ID. A journal entry is a balanced set of line entries, each a debit or credit to one ledger, i.e. a general ledger (GL) account in the organization's chart of accounts. The response includes the journal entry's datetime, description, creation source, categorization and review status, and the IDs of its line entries; pass expand=lineEntries to include the line entries themselves, with their ledger IDs, amounts, and debit/credit direction. Use this when you already know the journal entry ID; to search or browse journal entries, use listBooksJournalEntries.
Request
- Base URLhttps://api.mercury.com/api/v1
- AuthHTTP bearer
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Path parameters
unique id for a journal entry; emitted as base-58, but a base-16 UUID is also accepted
Query parameters
The Books instance to act on. Must be the token organization's own instance, which it defaults to.
Comma-separated list of expandable paths.
Response
Example response
{
"journalEntry": {
"accrualSource": {
"dueDate": "2016-07-22",
"effectiveDate": "2016-07-22",
"files": [
{
"id": "7JRNsKwy2Lw66caxVU7WGC"
}
],
"id": "7JRNsKwy2Lw66caxVU7WGC",
"journalEntryIds": [
"7JRNsKwy2Lw66caxVU7WGC"
],
"lines": [
{
"accountId": "7JRNsKwy2Lw66caxVU7WGC",
"accrualSourceId": "7JRNsKwy2Lw66caxVU7WGC",
"id": "7JRNsKwy2Lw66caxVU7WGC"
}
],
"paymentApplications": [
{
"adjustments": [
{
"accrualAdjustmentId": "7JRNsKwy2Lw66caxVU7WGC",
"creditAccountId": "7JRNsKwy2Lw66caxVU7WGC",
"debitAccountId": "7JRNsKwy2Lw66caxVU7WGC"
}
],
"lineEntry": {
"journalEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"lineEntryId": "7JRNsKwy2Lw66caxVU7WGC"
},
"paymentApplicationId": "7JRNsKwy2Lw66caxVU7WGC"
}
]
},
"autocatResult": {
"createdAt": "2016-07-22T00:00:00Z",
"ledgerId": "7JRNsKwy2Lw66caxVU7WGC"
},
"creationDate": "2016-07-22T00:00:00Z",
"datetime": "2016-07-22T00:00:00Z",
"id": "7JRNsKwy2Lw66caxVU7WGC",
"lineEntries": [
{
"accrualSource": {
"dueDate": "2016-07-22",
"effectiveDate": "2016-07-22",
"id": "7JRNsKwy2Lw66caxVU7WGC",
"lines": [
{
"accountId": "7JRNsKwy2Lw66caxVU7WGC",
"accrualSourceId": "7JRNsKwy2Lw66caxVU7WGC",
"id": "7JRNsKwy2Lw66caxVU7WGC"
}
]
},
"datetime": "2016-07-22T00:00:00Z",
"id": "7JRNsKwy2Lw66caxVU7WGC",
"journalEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"ledgerId": "7JRNsKwy2Lw66caxVU7WGC",
"opposingLedgerIds": [
"7JRNsKwy2Lw66caxVU7WGC"
],
"paymentApplications": [
{
"accrualSource": {
"accrualSourceId": "7JRNsKwy2Lw66caxVU7WGC",
"endDate": "2016-07-22",
"startDate": "2016-07-22"
},
"linePaymentApplicationId": "7JRNsKwy2Lw66caxVU7WGC"
}
],
"relatedLineEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"tags": [
{
"id": "7JRNsKwy2Lw66caxVU7WGC",
"tagGroupId": "7JRNsKwy2Lw66caxVU7WGC"
}
],
"transaction": {
"datetime": "2016-07-22T00:00:00Z",
"journalEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"ledgerId": "7JRNsKwy2Lw66caxVU7WGC",
"lineEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"opposingLineEntryIds": [
"7JRNsKwy2Lw66caxVU7WGC"
],
"sourceAccountId": "7JRNsKwy2Lw66caxVU7WGC"
}
}
],
"lineEntryIds": [
"7JRNsKwy2Lw66caxVU7WGC"
],
"reviewStatusSetAt": "2016-07-22T00:00:00Z",
"transfer": {
"fromEntry": {
"datetime": "2016-07-22T00:00:00Z",
"journalEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"lineEntries": [
{
"accrualSource": {
"dueDate": "2016-07-22",
"effectiveDate": "2016-07-22",
"id": "7JRNsKwy2Lw66caxVU7WGC",
"lines": [
{
"accountId": "7JRNsKwy2Lw66caxVU7WGC",
"accrualSourceId": "7JRNsKwy2Lw66caxVU7WGC",
"id": "7JRNsKwy2Lw66caxVU7WGC"
}
]
},
"datetime": "2016-07-22T00:00:00Z",
"id": "7JRNsKwy2Lw66caxVU7WGC",
"journalEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"ledgerId": "7JRNsKwy2Lw66caxVU7WGC",
"opposingLedgerIds": [
"7JRNsKwy2Lw66caxVU7WGC"
],
"paymentApplications": [
{
"accrualSource": {
"accrualSourceId": "7JRNsKwy2Lw66caxVU7WGC",
"endDate": "2016-07-22",
"startDate": "2016-07-22"
},
"linePaymentApplicationId": "7JRNsKwy2Lw66caxVU7WGC"
}
],
"relatedLineEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"tags": [
{
"id": "7JRNsKwy2Lw66caxVU7WGC",
"tagGroupId": "7JRNsKwy2Lw66caxVU7WGC"
}
],
"transaction": {
"datetime": "2016-07-22T00:00:00Z",
"journalEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"ledgerId": "7JRNsKwy2Lw66caxVU7WGC",
"lineEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"opposingLineEntryIds": [
"7JRNsKwy2Lw66caxVU7WGC"
],
"sourceAccountId": "7JRNsKwy2Lw66caxVU7WGC"
}
}
]
},
"toEntry": {
"datetime": "2016-07-22T00:00:00Z",
"journalEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"lineEntries": [
{
"accrualSource": {
"dueDate": "2016-07-22",
"effectiveDate": "2016-07-22",
"id": "7JRNsKwy2Lw66caxVU7WGC",
"lines": [
{
"accountId": "7JRNsKwy2Lw66caxVU7WGC",
"accrualSourceId": "7JRNsKwy2Lw66caxVU7WGC",
"id": "7JRNsKwy2Lw66caxVU7WGC"
}
]
},
"datetime": "2016-07-22T00:00:00Z",
"id": "7JRNsKwy2Lw66caxVU7WGC",
"journalEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"ledgerId": "7JRNsKwy2Lw66caxVU7WGC",
"opposingLedgerIds": [
"7JRNsKwy2Lw66caxVU7WGC"
],
"paymentApplications": [
{
"accrualSource": {
"accrualSourceId": "7JRNsKwy2Lw66caxVU7WGC",
"endDate": "2016-07-22",
"startDate": "2016-07-22"
},
"linePaymentApplicationId": "7JRNsKwy2Lw66caxVU7WGC"
}
],
"relatedLineEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"tags": [
{
"id": "7JRNsKwy2Lw66caxVU7WGC",
"tagGroupId": "7JRNsKwy2Lw66caxVU7WGC"
}
],
"transaction": {
"datetime": "2016-07-22T00:00:00Z",
"journalEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"ledgerId": "7JRNsKwy2Lw66caxVU7WGC",
"lineEntryId": "7JRNsKwy2Lw66caxVU7WGC",
"opposingLineEntryIds": [
"7JRNsKwy2Lw66caxVU7WGC"
],
"sourceAccountId": "7JRNsKwy2Lw66caxVU7WGC"
}
}
]
}
}
}
}Changes
- info
endpoint added
- info