Fixed AssetsDispose of a fixed asset

Dispose of a fixed asset

POST/partners/fixed-assets/{uuid}/dispose

Writes off or sells a registered asset and posts the disposal journal.

Depreciation is first posted up to `lastDepreciationDate`, in the same database transaction as the disposal: if the disposal is refused, nothing is posted. Send the account the outcome needs, or the call is refused with 400 rather than posting a journal that does not balance: `lossOnDisposalAccountUuid` for a write-off or a sale below book value, `gainOnDisposalAccountUuid` for a sale above book value, and `capitalGainAccountUuid` as well for a sale above cost. `disposalJournal` returns the journal entry UUID in `jeHeaderId`, its lines, the book value and the gain or loss.

HMAC signature + Bearer access token
Try this request

Headers

Idempotency-Keystringoptional

Client-generated key that makes the call safely retryable. Repeating a key replays the original response; reusing one with a different body is refused.

Path parameters

uuiduuidrequired

The fixed asset UUID (`id` from List fixed assets).

Request body

disposalDatedaterequired

YYYY-MM-DD. Not in the future.

disposalMethodenumrequired

How the asset leaves the register.

One of: write_off, sale

lastDepreciationDatedaterequired

Depreciation is posted up to this date before the disposal. On or before `disposalDate`.

salePricenumber

Required for a sale. 0 or more.

proceedsAccountUuiduuid

Where the sale proceeds land. Required for a sale.

lossOnDisposalAccountUuiduuid

Needed for a write-off or a sale below book value.

gainOnDisposalAccountUuiduuid

Needed for a sale above book value.

capitalGainAccountUuiduuid

Needed as well for a sale above cost.

gstTreatmentenum

GST on the sale price. `inclusive` and `exclusive` need `gstAccountUuid`.

One of: inclusive, exclusive, zero_rated, no_gst

gstAccountUuiduuid

Required when `gstTreatment` is `inclusive` or `exclusive`.

Responses

200The disposed asset and its disposal journal.
400The asset is not registered, a date is in the future or out of order, or the account the outcome needs (or `gstAccountUuid`) is missing.
404No asset, or no account with one of the UUIDs, in this workspace.
401Missing or invalid HMAC signature, expired timestamp, or invalid Bearer token. Troubleshoot
403The credential does not have access to this workspace or resource. Troubleshoot
429Rate limit exceeded (100 requests per minute per user of each app, or 10,000 per minute per app). Retry after the Retry-After header. Troubleshoot
POSThttps://api.getcount.com/partners/fixed-assets/{uuid}/dispose
Request
import crypto from 'node:crypto';

const BASE_URL = 'https://api.getcount.com';
const CLIENT_ID = process.env.COUNT_CLIENT_ID;
const CLIENT_SECRET = process.env.COUNT_CLIENT_SECRET;
const ACCESS_TOKEN = process.env.COUNT_ACCESS_TOKEN;

const method = 'POST';
const signingPath = '/fixed-assets/3fa85f64-5717-4562-b3fc-2c963f66afa6/dispose';
const timestamp = Math.floor(Date.now() / 1000).toString();
const body = {
  "disposalDate": "2026-11-15",
  "disposalMethod": "sale",
  "lastDepreciationDate": "2026-11-15",
  "salePrice": 1800,
  "proceedsAccountUuid": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c10",
  "lossOnDisposalAccountUuid": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c11",
  "gstTreatment": "inclusive",
  "gstAccountUuid": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c12"
};
const bodyString = JSON.stringify(body);

const bodyHash = crypto.createHash('sha256').update(bodyString).digest('hex');
const baseString = `${method}:${signingPath}:${timestamp}:${bodyHash}`;
const signature = crypto.createHmac('sha256', CLIENT_SECRET).update(baseString).digest('hex');

const response = await fetch(`${BASE_URL}/partners/fixed-assets/3fa85f64-5717-4562-b3fc-2c963f66afa6/dispose`, {
  method,
  headers: {
    'x-client-id': CLIENT_ID,
    'x-timestamp': timestamp,
    'x-signature': signature,
    'Content-Type': 'application/json',
    Authorization: `Bearer ${ACCESS_TOKEN}`,
    'Idempotency-Key': '3fa85f64-5717-4562-b3fc-2c963f66afa6',
  },
  body: bodyString,
});

console.log(await response.json());
Response · 200
{
  "status": "success",
  "message": "Success on disposing of fixed asset",
  "data": {
    "asset": {
      "id": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1a01",
      "assetNumber": "FA-0007",
      "name": "MacBook Pro 16\"",
      "description": "Design team laptop",
      "serialNumber": "C02XK1ABCD12",
      "location": "Head office",
      "status": "disposed",
      "statusLabel": "disposed",
      "origin": "derived",
      "costSource": "linked_journals",
      "fixedAssetTypeId": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1d01",
      "fixedAssetType": {
        "id": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1d01",
        "name": "Computer Equipment",
        "assetAccount": {
          "id": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c01",
          "name": "Computer Equipment"
        },
        "accumulatedDepreciationAccount": {
          "id": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c02",
          "name": "Accumulated Depreciation - Computer Equipment"
        },
        "depreciationExpenseAccount": {
          "id": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c03",
          "name": "Depreciation"
        },
        "defaultDepreciationMethod": "diminishing_value",
        "defaultAveragingMethod": "full_month",
        "defaultDepreciationFrequency": "monthly",
        "defaultCalculateBasis": "rate",
        "defaultRate": "50.0000",
        "defaultEffectiveLife": null,
        "createdAt": "2026-01-15T10:30:00.000Z",
        "updatedAt": "2026-01-28T14:22:30.000Z"
      },
      "purchaseDate": "2026-07-14",
      "purchasePrice": "3200.0000",
      "depreciationStartDate": "2026-07-14",
      "depreciationMethod": "diminishing_value",
      "averagingMethod": "full_month",
      "depreciationFrequency": "monthly",
      "calculateBasis": "rate",
      "rate": "50.0000",
      "effectiveLife": null,
      "insuranceValue": null,
      "replacementValue": null,
      "claimInvestmentBoost": false,
      "registeredAt": "2026-07-20T02:15:00.000Z",
      "disposalDate": "2026-11-15",
      "disposalMethod": "sale",
      "disposalPrice": "1800.0000",
      "journalLinks": [
        {
          "id": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1e01",
          "sourceType": "bill",
          "billId": "0190a1b2-c3d4-7e5f-8a9b-0c1d2e3f4a01",
          "transactionId": null,
          "jeHeaderId": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1f01",
          "amount": "3200.0000",
          "grossAmount": "3680.0000",
          "gstAmount": "480.0000",
          "description": "MacBook Pro 16\"",
          "isPrimaryJournalLink": true,
          "canUnlinkJournalEntry": false
        }
      ],
      "createdByUser": {
        "firstName": "Ana",
        "lastName": "Reyes"
      },
      "createdAt": "2026-01-15T10:30:00.000Z",
      "updatedAt": "2026-01-28T14:22:30.000Z"
    },
    "disposalJournal": {
      "jeHeaderId": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b2c01",
      "lines": [
        {
          "accountId": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c10",
          "amountDebit": 1800,
          "amountCredit": 0
        },
        {
          "accountId": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c02",
          "amountDebit": 482.24,
          "amountCredit": 0
        },
        {
          "accountId": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c11",
          "amountDebit": 1152.54,
          "amountCredit": 0
        },
        {
          "accountId": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c12",
          "amountDebit": 0,
          "amountCredit": 234.78
        },
        {
          "accountId": "0194c1d2-3e4f-7a5b-8c6d-7e8f9a0b1c01",
          "amountDebit": 0,
          "amountCredit": 3200
        }
      ],
      "bookValue": 2717.76,
      "accumulatedDepreciation": 482.24,
      "netSalePrice": 1565.22,
      "gainOrLoss": -1152.54,
      "capitalGain": 0
    }
  }
}