Skip to content

Filter Syntax

oikapi uses function-based filter syntax in URL query parameters.

GET /api/apps/{app}/tables/{table}/records?filter=eq(status,'active')
OperatorDescriptionExample
eqEqualeq(status,'active')
neNot equalne(status,'canceled')
gtGreater thangt(budget,5000)
gteGreater or equalgte(priority,3)
ltLess thanlt(due_date,'2025-12-31')
lteLess or equallte(budget,100000)
likePattern match (case-sensitive)like(name,'%acme%')
ilikePattern match (case-insensitive)ilike(name,'%acme%')
containsSubstring (case-insensitive)contains(name,'acme')
not_containsDoes not contain substringnot_contains(name,'test')
starts_withStarts with (case-insensitive)starts_with(name,'acme')
ends_withEnds with (case-insensitive)ends_with(name,'inc')
inIn setin(status,['active','draft'])
not_inNot in setnot_in(status,['canceled'])
betweenRangebetween(budget,1000,5000)
is_nullIs nullis_null(deleted_at)
is_not_nullIs not nullis_not_null(assigned_to)

Aliases: isnull for is_null, isnotnull or not_null for is_not_null.

Combine conditions with and, or, and not:

# AND
?filter=and(eq(status,'active'),gt(budget,5000))
# OR
?filter=or(eq(priority,'high'),eq(priority,'critical'))
# NOT
?filter=not(eq(status,'canceled'))
# Nested
?filter=or(
eq(priority,'high'),
and(
eq(status,'open'),
lt(due_date,'2025-12-31')
)
)
OperatorDescriptionExample
array_containsArray includes valuearray_contains(tags,'urgent')
array_overlapsArrays share any elementarray_overlaps(tags,['urgent','bug'])
array_emptyArray is emptyarray_empty(tags)
array_not_emptyArray is not emptyarray_not_empty(tags)
OperatorDescriptionExample
date_after_days_agoWithin last N daysdate_after_days_ago(created_at,7)
date_before_days_agoOlder than N daysdate_before_days_ago(created_at,30)
date_in_rangeWithin a named rangedate_in_range(due_date,'this_month')

date_in_range takes a named-range keyword as its second argument. Valid keywords: today, yesterday, this_week, last_week, this_month, last_month, this_quarter, last_quarter, this_year, last_year.

  • String values must be quoted: eq(status,'active')
  • Numeric values are unquoted: gt(budget,5000)
  • Date values are strings: lt(due_date,'2025-12-31')
  • Use contains for case-insensitive text searches
  • Combine is_null / is_not_null to filter on optional fields