Skip to main content
PATCH
/
v1
/
businesses
/
{businessId}
/
assets
/
{assetId}
Update an asset
curl --request PATCH \
  --url https://sandbox.layerfi.com/v1/businesses/{businessId}/assets/{assetId} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "accumulated_depreciation_account": {
    "type": "AccountId",
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  },
  "original_value": 123,
  "salvage_value": 123,
  "useful_life_months": 123,
  "memo": "<string>",
  "metadata": {},
  "reference_number": "<string>"
}
'
{
  "data": {
    "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "business_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
    "name": "<string>",
    "ledger_account": {
      "type": "Single_Chart_Account",
      "id": {
        "type": "AccountId",
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      },
      "name": "Current Assets",
      "account_number": "4000",
      "stable_name": {
        "type": "StableName",
        "stable_name": "CURRENT_ASSETS"
      },
      "account_type": {
        "display_name": "Asset"
      },
      "account_subtype": {
        "display_name": "Current Assets"
      }
    },
    "transaction_tags": [
      {
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "key": "ExampleTagKey",
        "value": "ExampleTagValue",
        "dimension_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "definition_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
        "dimension_display_name": "<string>",
        "value_display_name": "<string>",
        "archived_at": "2023-11-07T05:31:56Z"
      }
    ],
    "external_id": "<string>",
    "accumulated_depreciation_account": {
      "type": "Single_Chart_Account",
      "id": {
        "type": "AccountId",
        "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
      },
      "name": "Current Assets",
      "account_number": "4000",
      "stable_name": {
        "type": "StableName",
        "stable_name": "CURRENT_ASSETS"
      },
      "account_type": {
        "display_name": "Asset"
      },
      "account_subtype": {
        "display_name": "Current Assets"
      }
    },
    "original_value": 123,
    "salvage_value": 123,
    "useful_life_months": 123,
    "archived_at": "2023-11-07T05:31:56Z",
    "memo": "<string>",
    "metadata": {},
    "reference_number": "<string>"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

businessId
string<uuid>
required

The UUID of the business.

assetId
string<uuid>
required

The UUID of the asset.

Body

application/json

The asset fields to update.

Parameters for updating an asset. Only include the fields you want to change.

name
string

Updated asset name.

asset_type
enum<string>

The type of fixed asset.

Available options:
RIGHT_OF_USE_ASSET,
VEHICLE,
EQUIPMENT,
GOODWILL
accumulated_depreciation_account
Account ID · object

Updated accumulated depreciation account.

original_value
integer<int64> | null

Updated original value, in cents.

salvage_value
integer<int64> | null

Updated salvage value, in cents.

useful_life_months
integer<int32> | null

Updated useful life, in months.

memo
string | null

Updated internal note.

metadata
object

Arbitrary JSON object you can attach for your own use. Layer stores and returns it unchanged.

reference_number
string | null

Updated reference number.

Response

200 - application/json

The updated asset.

data
object
required

A fixed asset held by a business. Each asset has a dedicated ledger account.