Skip to main content
PATCH
/
v0
/
business
/
{business_id}
/
ledger
/
{ledger_id}
Update a Ledger
curl --request PATCH \
  --url https://api.sandbox.getasset.com/v0/business/{business_id}/ledger/{ledger_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "description": "<string>",
  "type": "asset",
  "subtype": "current_asset",
  "financial_account_type": "bank_account",
  "debit_credit": "debit",
  "sort_code": "<string>",
  "report_cash_flow": true,
  "parent_id": "<string>"
}
'
{
  "data": {
    "name": "<string>",
    "type": "asset",
    "subtype": "current_asset",
    "debit_credit": "debit",
    "report_cash_flow": true,
    "id": "<string>",
    "business_id": "<string>",
    "description": "Business checking account",
    "financial_account_type": "bank_account",
    "sort_code": "1010",
    "parent_id": "ldg_KtY7p9fsM4pB58SYNar7cv"
  }
}

Documentation Index

Fetch the complete documentation index at: https://docs.getasset.com/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

The access token received from the authorization server in the OAuth 2.0 flow.

Path Parameters

business_id
string<biz_string>
required

The id of the business

Example:

"biz_GA6EG2qFxA97NZHtxeLPUy"

ledger_id
string<ldg_string>
required

The id of the ledger

Example:

"ldg_WQMDNUHpBThYSNh4AprDBo"

Body

application/json
name
string | null

The name of the ledger

description
string | null

Description of the ledger. Set to null if you want to clear the existing value.

Maximum string length: 100
type
enum<string> | null

The ledger type

Available options:
asset,
liability,
equity,
revenue,
expense
subtype
enum<string> | null

The ledger subtype

Available options:
current_asset,
fixed_asset,
other_asset,
uncategorized_asset,
current_liability,
long_term_liability,
operating_revenue,
other_inflow,
cost_of_goods_sold,
operating_expense,
other_outflow,
contribution,
distribution,
common_stock,
preferred_stock,
additional_capital,
opening_balance,
retained_earnings,
memo
financial_account_type
enum<string> | null

Used for ledgers that are connected to real-world financial accounts. Set to null if you want to clear the existing value.

Available options:
bank_account,
credit_card,
prepaid_card,
payments,
payroll,
loan,
accounts_receivable,
accounts_payable
debit_credit
enum<string> | null

Indicates if the ledger is a debit or credit ledger

Available options:
debit,
credit
sort_code
string | null

Used for grouping and sorting ledgers in reports. Set to null if you want to clear the existing value.

report_cash_flow
boolean | null

Whether the ledger is included in the cash flow report

parent_id
string<ldg_string> | null

It indicates if this is a child ledger of another ledger in the chart of accounts. Set to null if you want to clear the existing value.

Response

Successful Response

data
LedgerPublic · object
required