Querying

Chain after GET https://api.basic.tech/account/{project_id}/db/{table} endpoint as query params.

Filtering (filter)

const options = {method: 'GET'};

//example to filter where name equals John
fetch('https://api.basic.tech/account/{project_id}/db/{table}?name=eq.John', options)
  .then(response => response.json())
  .then(response => console.log(response))
  .catch(err => console.error(err));
  • Method: filter(conditions)
  • Supported Operators: eq, neq, gt, gte, lt, lte, like, ilike, in, not (see list of operators)

Ordering (order)

const options = {method: 'GET'};

//example to filter where created_at is descending, and name is ascending
fetch('https://api.basic.tech/account/{project_id}/db/{table}?order=created_at.desc,name.asc', options)
  .then(response => response.json())
  .then(response => console.log(response))
  .catch(err => console.error(err));
  • Method: order(field, direction?) (direction defaults to ‘asc’)

Pagination (limit, offset)

const options = {method: 'GET'};

//example to filter where limit is 10, offset is 20
fetch('https://api.basic.tech/account/{project_id}/db/{table}?limit=10&offset=20', options)
  .then(response => response.json())
  .then(response => console.log(response))
  .catch(err => console.error(err));
  • Methods: limit(count), offset(count)

Supported operators

OperatorDescriptionExample
eqEqualitystatus=eq.active
neqNot equalstatus=neq.deleted
gtGreater thanpriority=gt.3
gteGreater than or equalpriority=gte.3
ltLess thanpriority=lt.3
lteLess than or equalpriority=lte.3
likePattern (case sensitive)title=like.*project*
ilikePattern (case insensitive)title=ilike.*todo*
inValue in settags=in.work,important
notNegationtags=not.eq.work

Limitations

  • Only one filterable condition per field per query (no compound filters across multiple fields)
  • Range filters (e.g., ?field=gte.x&lte.y) not supported
  • Method chaining order is flexible, but all must be chained after GET https://api.basic.tech/account/{project_id}/db/{table}