Assets — list, create, read, update

Manage physical assets tied to a site and account. Reads use project-service GraphQL; creates and updates call fleet-service.

Endpoints

MethodPathDescription
GET/assetsList assets (filters, pagination, optional account_id)
POST/assetsCreate an asset
GET/assets/{assetId}Get asset by id
PATCH/assets/{assetId}Update asset fields, including archiving

Query parameters (GET /assets)

ParameterDescription
page, page_sizePagination (page_size max 100)
order_byasc or desc by createdAt (default desc)
account_idFilter by account
site_idFilter by site
status, typeExact match
manufacturerCase-insensitive contains
is_archivedtrue / false (default false)
updated_after, updated_beforeISO date-time filters on updatedAt

Create body highlights

  • Required: accountId, siteId, type, manufacturer, model, serialNumber.
  • Optional: status, labelIds, dates, description, image file ids, size, expectedLifetime.

PATCH notes

  • siteId and accountId cannot be changed after creation; PATCH requests that include either field are rejected by request validation with 400 rather than being silently ignored.
  • Set isArchived: true to archive an asset, or isArchived: false to unarchive it.

Invoice payments

New: List, get, and create payments on an invoice

You can list payments for an invoice, fetch a single payment by id, and record manual payments. Paths are scoped under the invoice (there is no global /payments resource).

MethodPathDescription
GET/invoices/{invoiceId}/paymentsList all payment records for an invoice
GET/invoices/{invoiceId}/payments/{paymentId}Get one payment on an invoice
POST/invoices/{invoiceId}/paymentsCreate a manual payment on an invoice

List returns a JSON array, get-by-id returns a single object, and create returns the payment service payload (amounts in dollars on reads; create accepts dollars and converts to cents for core).

Create a payment

POST /invoices/{invoiceId}/payments
1{
2 "amount": 125.5,
3 "paymentMethod": "CHECK",
4 "paymentDate": "2026-04-28T18:00:00.000Z",
5 "notes": "Deposit received",
6 "paymentReference": "CHK-1042"
7}

Notes

  • paymentReference and notes are optional.
  • paymentMethod must be one of: CASH, ACH, CREDIT_CARD, KLARNA, AFFIRM, CHECK.
  • Core does not expose GET /payment-records/:id; get-by-id resolves the payment from the invoice’s nested payment records.