The endpoint will automatically match the tenant information provided with an existing tenant within the system.At least one of the following tenant identifiers need to be provided:
Internal tenant identifier (identifier)
External tenant identifier (external_ref) and the group id the tenant belongs to (group)
The email address of the tenant (email_address)
The phone number of the tenant (phone_number)
If no tenant match is retrieved, an empty set of leases will be returned.Active leases have an end date in the future and a start date in the past relative to the current date.All date fields included in the body parameters need to be specified as ISO8601-formatted date strings.Date fields should follow a “YYYY-MM-DD” format.If finding tenants via their external referance, you must provide the group the tenant belongs to.The group can be specified via either the group_id or group_external_ref attribute.Do not provide both, as this will result in the request failing.
This endpoint allows you to find leases for a specific tenant.You can retrieve all leases for a tenant given their internal id or external reference and group id.You can retrieve all leases for a tenant given their phone number or email address.
The API returns a maximum of 100 records per call.You can use this parameter to load the next set of records by passing in the value returned in the response, under last_id.
The last id in the set of results returned for this API call.You can use this value in the after-id parameter to load the next set of results.If there are no more results to load, this value will be -1.
Listed below are common errors that may be returned by the endpoint, along with their corresponding status code.Status Code - 400
Missing Authorization header
Copy
Ask AI
{ "error": { "type": "missing_authorization", "message": "Your request does not include an 'Authorization' header with a bearer token for your account." }}
Status Code - 401
Expired Authorization header bearer token value
Copy
Ask AI
{ "error": { "type": "expired_token", "message": "The bearer token you have provided in the 'Authorization' header has expired. Please obtain a new one." }}
Status Code - 401
Invalid Authorization header bearer token value
Copy
Ask AI
{ "error": { "type": "invalid_authorization", "message": "The bearer token you have provided in the 'Authorization' header is invalid." }}
Status Code - 400Returned if none of the tenant parameters are provided in the request body
No tenant information
Copy
Ask AI
{ "error": { "type": "no_tenant_information", "message": "You need to provide at least one of identifier, external_ref AND group, email_address, or phone_number in the request body." }}
Status Code - 400Returned if both of the group_id and group_external_ref attributes are provided
Both group id and external ref provided for the find leases for tenant operation
Copy
Ask AI
{ "error": { "type": "both_group_identifiers_provided", "message": "You have provided both the group id and group external reference for the find leases for tenant operation. Please only provide one of the two." }}
Status Code - 400Returned if no group_id or group_external_ref is provdided when identifying a tenant via an external_ref
No group id or group external ref provided for tenant external reference.
Copy
Ask AI
{ "error": { "type": "both_group_identifiers_provided", "message": "You have not a group id or group external reference when identifying a tenant via their external reference. Please provide one of the two." }}