Lease charges

Create a recurring payment

Sets up a payment that is recorded on the lease each period, for a tenant who pays the same way every time. Set createPastPayments to true to record the ones that would already have happened.

POST
https://api.portal.magicdoor.com/company-app/leases/{leaseId}/charges/recurring-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

leaseIdstringrequired

The lease to add the recurring payment to. A Snowflake id, sent as a decimal string.

example: 1830472847398404096

Body

application/json

amountnumberrequired

Amount to record each period, as a decimal of at least 1.

paymentFrequencyenum<string>required

How often to record it.

monthlyweeklydailymonthly2XSplitquarterlyyearly
startFromstring · daterequired

First date to record a payment.

createPastPaymentsbooleanrequired

Whether to record the payments that fell due between startFrom and today.

endstring · date

Last date to record one. Must be later than startFrom.

tenantIdstring

Which tenant is paying. A Snowflake id, sent as a decimal string.

descriptionstring

Note on each payment. 1 to 1000 characters.

paymentMethodenum<string>

How the tenant pays. Defaults to other when left out.

checkcashiersCheckmoneyOrdercashother
referencestring

Reference to carry on each payment. Up to 150 characters.

Response

200 · The recurring payment that was created.

idstring

Id of the recurring payment. A Snowflake id, sent as a decimal string.

leaseIdstring

The lease it pays. A Snowflake id, sent as a decimal string.

tenantIdstring

The tenant it is recorded against. A Snowflake id, sent as a decimal string.

portfolioIdstring

Portfolio it rolls up to. A Snowflake id, sent as a decimal string.

propertyIdstring

Property it is on. A Snowflake id, sent as a decimal string.

unitIdstring

Unit it is on. A Snowflake id, sent as a decimal string.

amountnumber

Amount recorded each period, as a decimal.

paymentFrequencyenum<string>

How often it is recorded.

monthlyweeklydailymonthly2XSplitquarterlyyearly
paymentMethodenum<string>

How the tenant pays.

achdebitCardwalletcreditCardcheckcashiersCheckmoneyOrdercashother
descriptionstring

Note on the payment.

referencestring

External reference carried on each payment.

lastPaymentstring · date

When it last recorded a payment.

nextPaymentstring · date

When it next records one.

startFromstring · date

First date it records a payment.

endstring · date

Last date it records one. Absent when it runs indefinitely.

statusenum<string>

Whether it is still running, has finished, or is about to record a payment.

activeendeddueSoon
tenantobject

The tenant it is recorded against.

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.

404 · No lease matched the id, or it belongs to another company.