Units

List money taken in on a unit

Returns a page of incoming transactions on the unit — rent and other lease charges, and security deposits. Money paid out, and every other kind of transaction, is left out.

GET
https://api.portal.magicdoor.com/company-app/units/{unitId}/payments

Authorization

Authorizationstringrequired
Bearer token — Send your API token in the Authorization header as Bearer <token>. Requests without a valid token are rejected with 401 Unauthorized.

Path parameters

unitIdstringrequired

Snowflake id of the unit, as a decimal string.

example: 1830472847398404098

Query parameters

pageinteger

Which page to return. Starts at 1.

default: 1
pageSizeinteger

How many records per page. Between 1 and 100. Defaults to 50.

default: 50

Response

200 · One page of transactions, plus the bank accounts, ledger accounts, properties, units, leases, tenants, vendors, subsidizers and owners they point at, each expanded once.

itemsTransaction[]

The transactions on this page. The list below covers the fields that matter for a unit's incoming money; the transactions endpoints document the type in full.

currentPageinteger

The page you asked for. Note the name: this endpoint calls it currentPage, not page.

totalPagesinteger

How many pages the filtered set fills at this page size.

pageSizeinteger

How many records a page holds.

totalCountinteger

How many records match the filter across every page.

bankAccountsBankAccount[]

The bank accounts the items reference, expanded once each.

chartOfAccountsChartOfAccount[]

The ledger accounts the items reference, expanded once each.

propertiesProperty[]

The properties the items reference.

unitsUnit[]

The units the items reference.

leasesLease[]

The leases the items reference.

tenantsTenant[]

The tenants the items reference.

vendorsVendor[]

The vendors the items reference. Empty in practice on this endpoint.

subsidizersSubsidizer[]

The subsidizers the items reference.

ownersOwner[]

The owners the items reference. Empty in practice on this endpoint.

400 · `page` is below 1 or `pageSize` is outside 1 to 100. The response carries an `errors` member mapping each rejected field name to its message.

401 · The access token is missing, expired, or not for this company.

The filter is fixed

This endpoint always narrows to incoming transactions whose identity is leaseCharge or leaseDeposit. There is no parameter to widen it. For a full transaction ledger use the transactions endpoints.

This envelope names the page `currentPage`

The rest of the MagicDoor API returns page in its pagination envelope. The legacy Portal endpoints, including this one, return currentPage instead. The request parameter is still page.