List leases
Returns a page of the company's leases, each with its unit, property and tenants already filled in, plus the company's custom-field definitions so you can read the values on each lease.
Authorization
AuthorizationstringrequiredQuery parameters
pageintegerWhich page to return. Starts at 1.
pageSizeintegerHow many rows per page, between 1 and 100.
searchstringFree-text search across the leases.
leaseStart.startstring · date-timeOnly leases whose start date is on or after this instant.
leaseStart.endstring · date-timeOnly leases whose start date is on or before this instant.
leaseEnd.startstring · date-timeOnly leases whose end date is on or after this instant.
leaseEnd.endstring · date-timeOnly leases whose end date is on or before this instant.
monthToMonthbooleanOnly leases that do, or do not, continue month to month.
evictionbooleanOnly leases that are, or are not, flagged for eviction.
endedbooleanOnly leases that have, or have not, been ended. Note that an expired lease has not been ended.
draftbooleanOnly draft leases, or only activated ones.
withBalancebooleanSet to true for only leases whose balance is above zero. Ignored when balance.from or balance.to is given.
withPostedBalancebooleanSet to true for only leases whose settled balance is above zero. Ignored when postedBalance.from or postedBalance.to is given.
balance.fromnumberLowest balance to include.
balance.tonumberHighest balance to include.
balance.includeFrombooleanWhether balance.from itself counts as a match.
balance.includeTobooleanWhether balance.to itself counts as a match.
postedBalance.fromnumberLowest settled balance to include.
postedBalance.tonumberHighest settled balance to include.
postedBalance.includeFrombooleanWhether postedBalance.from itself counts as a match.
postedBalance.includeTobooleanWhether postedBalance.to itself counts as a match.
tenantIdsstring[]Only leases that include any of these tenants.
unitIdsstring[]Only leases on any of these units.
propertyIdsstring[]Only leases on any of these properties.
portfolioIdsstring[]Only leases in any of these portfolios.
unitIdstringOnly leases on this unit. Ignored when unitIds is given.
propertyIdstringOnly leases on this property. Ignored when propertyIds is given.
portfolioIdstringOnly leases in this portfolio. Ignored when portfolioIds is given.
Response
200 · A page of leases.
itemsHydratedLease[]The rows on this page.
currentPageintegerThe page you asked for. Pages start at 1.
totalPagesintegerHow many pages exist at this page size.
pageSizeintegerHow many rows a page holds.
totalCountintegerHow many rows match in total, across all pages.
customFieldsCustomField[]The company's custom-field definitions for leases, so the customFieldValues on each row can be labelled.
400 · The request failed validation. `errors` maps each field name to what was wrong with it.
401 · The access token is missing, expired, or not for this company.
A lease is a draft until it is activated, future before its start date, and a live lease after that. When a fixed term runs past its end date the lease becomes expired, which in MagicDoor is a normal ongoing state — rent keeps being charged and nothing about the lease is cancelled. Expiry never turns into ending. A lease only becomes ended when someone ends it, and eviction is a separate flag that can be set while the lease is live.