ContractFilterDTO
Request body for POST /v1/open-api/contract/filter. All fields are optional except
pagination; an omitted or empty-array filter matches everything. Deleted contracts
are excluded unless includeDeleted/deletedOnly is set.
Page number, 1-based (min 1).
Possible values: >= 1
11Page size (min 1, max 100 — higher than most other filters).
Possible values: >= 1 and <= 100
1515orders object
Sort order. Each key is a sort field (see ContractOrderField) and each value a
direction. Keys are applied in the order they appear in the JSON object.
Unless ID is one of the keys, a trailing ID DESC tie-breaker is appended so
paging stays stable across requests. Omit (or send {}) to keep the default —
newest ID first (ID DESC).
Possible values: [ASC, DESC]
Free-text match over contract number, pay number, client name and phone.
CNT-2023Exact contract IDs (bulk re-sync).
[1409,1410]Filter by contract number (exact match).
CNT-2023-001Lower bound (inclusive) of the contract date (createdTimestamp), epoch seconds. For day-level filtering, convert the local day boundary to epoch seconds yourself.
1735668000Upper bound (inclusive) of the contract date (createdTimestamp), epoch seconds.
1767207599Lower bound (inclusive) of the time the contract was entered into the system — matches the response's registeredTimestamp.
1735689600Upper bound (inclusive) of the time the contract was entered into the system.
1767207599Lower bound (inclusive) of the cancellation time (canceledTimestamp), epoch seconds.
1735689600Upper bound (inclusive) of the cancellation time.
1767207599Filter by responsible employee IDs.
[201,202]Filter by the employee who created the contract.
[95]Filter by client IDs.
[5001]Filter by currency IDs.
[1,2]Filter by contract statuses.
Possible values: [STARTED, ACTIVE, CANCELLED, FINISHED, TRANSFERRED]
["ACTIVE","STARTED"]Filter by house (project) IDs.
[12]Filter by building (block) IDs.
[34]Filter by apartment IDs.
[7781]Apartment number — exact match.
45true — only formal contracts, false — only informal. null (omit) — don't filter.
trueOnly contracts whose apartment is repaired. null (omit) — don't filter.
trueFilter by payment status.
Possible values: [PAID, UN_PAID]
["PAID"]Filter by payment way.
Possible values: [MONTHLY_PAYMENT, PREPAYMENT, BOTH]
["BOTH"]true — only contracts with a discount. null (omit) — don't filter.
truetrue — also include deleted contracts. Default false.
falsetrue — only deleted contracts; takes priority over includeDeleted. Default false.
falsecustomFields object[]
Custom field conditions — see CustomFieldFilter. List entries are AND'ed; a
single entry's values are OR'ed (IN). Supersedes the deprecated fields map.
CRM custom field ID to filter on. Required.
42Field type, decides how the condition is interpreted. Defaults to TEXT.
Possible values: [TEXT, EXTENDED_TEXT, DATE, SELECT, MULTI_SELECT, RADIO, TOGGLE_SWITCH, URL, TAG, LOCATION, COUNTER, ADDRESS, EMPLOYEE, FILE, NUMBER]
TEXTSELECTValues to match (OR between them). Used for every type except NUMBER, and
ignored when hasValue is sent. For ADDRESS send comma-separated Uzbek
place names (see the description above).
["VIP"]Lower bound for NUMBER fields (inclusive). Defaults to 0 when omitted.
1000Upper bound for NUMBER fields (inclusive). Unbounded when omitted.
5000Restrict a NUMBER condition to one currency (optional). When omitted, any currency matches.
24Presence check. true → the lead has any value for this field, false → it has
none. Overrides values / numberStart / numberFinish / currencyId.
truefields objectdeprecated
Deprecated — use customFields instead. Contract custom field id → value, exact match. All pairs are AND'ed; combines with customFields via AND when both are sent.
Deprecated — use contractTimestampFrom instead. Lower bound of the contract date (dd.MM.yyyy), converted to the start of the day in the company's timezone. If both are sent, the later of the two lower bounds is used.
01.01.2025Deprecated — use contractTimestampTo instead. Upper bound of the contract date (dd.MM.yyyy), converted to the end of the day (23:59:59) in the company's timezone. If both are sent, the earlier of the two upper bounds is used.
31.12.2025Deprecated — use currencyIds instead. Ignored when currencyIds is also sent.
[1,2]{
"page": 1,
"size": 15,
"orders": {
"CONTRACT_DATE": "DESC",
"AMOUNT": "ASC"
},
"search": "CNT-2023",
"ids": [
1409,
1410
],
"contractNumber": "CNT-2023-001",
"contractTimestampFrom": 1735668000,
"contractTimestampTo": 1767207599,
"registeredTimestampFrom": 1735689600,
"registeredTimestampTo": 1767207599,
"cancelTimestampFrom": 1735689600,
"cancelTimestampTo": 1767207599,
"responsibleByIds": [
201,
202
],
"createdByIds": [
95
],
"clientIds": [
5001
],
"currencyIds": [
1,
2
],
"statuses": [
"ACTIVE",
"STARTED"
],
"houseIds": [
12
],
"buildingIds": [
34
],
"flatIds": [
7781
],
"flatNumber": "45",
"formal": true,
"flatRepaired": true,
"paymentStatuses": [
"PAID"
],
"paymentWays": [
"BOTH"
],
"discounted": true,
"includeDeleted": false,
"deletedOnly": false,
"customFields": [
{
"customFieldId": 42,
"type": "SELECT",
"values": [
"VIP"
],
"numberStart": 1000,
"numberFinish": 5000,
"currencyId": 24,
"hasValue": true
}
]
}