Properties

Set a property's photo

Points the property at an uploaded file as its main photo. Pass the id of an upload session you have already sent the bytes to.

PUT
https://api.portal.magicdoor.com/company-app/properties/{propertyId}/image

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

propertyIdstringrequired

Snowflake id of the property, as a decimal string.

example: 1830472847398404097

Body

application/json

Give exactly one of the two. Send neither and the property's photo is cleared.

uploadSessionIdstring

Id of a completed upload session from Start a property photo upload.

fileIdstringdeprecated

Id of an already-uploaded but unclaimed file. Use uploadSessionId instead.

Response

200 · The property, hydrated, with `image` and `imageId` now pointing at the file.

idstring

Snowflake id of the property.

namestring

The name a property manager gave the property. Absent when the property was never named.

displayNamestring

What to show in a list: the name if there is one, otherwise streetAddress1, otherwise the literal "Unnamed Property". Computed on every read.

addressobject

The property's address. Absent when no address has been recorded.

portfolioIdstring

The portfolio this property sits in.

typeenum<string>

What kind of building this is. A singleFamily or condo property, and a townHome with exactly one unit, is treated as a single-unit property elsewhere in the API.

singleFamilymultiFamilycommercialcondotownHomeother
totalFloorsinteger

Number of floors in the building, 1 to 200. Absent when it was never set.

unitCountinteger

How many units belong to the property, active and deactivated together. Maintained by MagicDoor as units are created and deleted; you cannot set it.

recentRentalApplicationsinteger

How many rental applications naming this property arrived in the recent window. Computed; you cannot set it.

activeboolean

false once the property has been deactivated.

imageIdstring

The file behind the property's main photo. Absent when no photo has been set.

iconsstring[]

Icon keys pinned to the property. Free-form strings.

magicTagsobject

Free-form labels on the property, as a map of string keys to string values. MagicDoor stores them as given and uses them to scope things like vendor bills. Absent when none are set.

imageobject

The property's main photo, resolved from imageId. Absent when no photo has been set.

portfolioobject

The portfolio this property sits in, expanded.

totalRentnumber

Computed: the sum of currentRent across the property's active leases. Not stored — you cannot set it.

currentBalancenumber

Computed: the sum of balance across the property's active leases. A positive figure means tenants owe money.

postedBalancenumber

Computed: the sum of postedBalance across the property's active leases — the same total as currentBalance but counting only charges that have already been posted.

totalDepositnumber

Computed: the sum of securityDepositPaid across the property's active leases.

occupiedUnitsinteger

Computed: how many distinct units of this property have an active lease.

activeUnitsinteger

Computed: how many of the property's units are active. Differs from unitCount, which also counts deactivated units.

emptyUnitsinteger

Computed as activeUnits minus occupiedUnits.

ownersobject[]

Who owns the property and in what share. Empty when no owner has been linked.

defaultUnitobject

The property's only unit, returned when the property is a single-unit one — singleFamily, condo, or a townHome with exactly one unit. Absent otherwise.

400 · Neither id is a decimal number, or the session does not belong to this property. 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.

404 · No property with that id, or it belongs to another company.

422 · The property has been deactivated, so its photo cannot be changed.

One photo, not a gallery

A property has a single main photo, stored as imageId. Calling this again replaces it. A gallery of marketing photos belongs on the unit listing, not here.