Query and Driver Engine

ObjectQL

The infrastructure query engine inside ObjectStack

ObjectQL is the internal query engine and driver contract used by ObjectStack. It helps ObjectStack applications read and search heterogeneous data sources while ObjectOS enforces identity, permissions, audit, and AI tool boundaries. It is infrastructure for the development and runtime platforms, not the product center.

What ObjectQL Does

Portable data access for ObjectStack applications and ObjectOS runtime execution.

Unified Query Shape

Filters, sorting, pagination, joins, expansion, aggregation, and projections are represented as structured query metadata instead of route-specific SQL strings.

Driver Contract

Drivers translate ObjectQL operations into native SQL, MongoDB pipelines, spreadsheet reads, SaaS API calls, or custom enterprise protocols while keeping the object contract stable.

Permission-Aware Execution

ObjectOS applies tenant isolation, row-level rules, field redaction, audit, and AI identity around every ObjectQL-backed operation.

Readable for AI Tools

Structured queries let REST APIs, ObjectUI views, SDKs, and MCP tools expose safe data access without handing AI raw SQL.

Query layer

ObjectQL stays in the infrastructure layer

It describes data-access intent, lets drivers translate to native systems, and stays wrapped by ObjectOS permissions and audit.

01 Request

Views, APIs, SDKs, or MCP tools issue structured queries

02 Query contract

ObjectQL represents filters, paging, joins, projections

03 Driver

Translate to SQL, documents, spreadsheets, or SaaS APIs

04 Governance

ObjectOS applies tenant, field, row permissions, audit

From portable query to native execution

ObjectQL describes intent; each driver executes it in the language of its data source.

ObjectQL Query

await objectql.find('customer', {
  where: {
    industry: { eq: 'manufacturing' },
    annualRevenue: { gte: 10000000 }
  },
  sort: [{ field: 'updatedAt', direction: 'desc' }],
  expand: ['accountManager'],
  limit: 50
});

Driver Execution

// PostgreSQL driver
SELECT * FROM customers
WHERE industry = $1 AND annual_revenue >= $2
ORDER BY updated_at DESC
LIMIT 50;

// MongoDB driver
db.customers.aggregate([...]);

// Excel driver
read workbook rows, apply filters, return typed records

Where ObjectQL Fits

Use ObjectQL when ObjectStack applications need portable, governed data access across sources.

Federated Enterprise Data

Mount Postgres, MongoDB, Excel, and legacy systems behind one query contract so applications can read them through consistent object metadata.

Custom Driver Development

Implement a driver for a proprietary database, SaaS API, mainframe, or file format and let ObjectStack expose it as governed objects.

AI Data Access Boundary

Expose permission-aware list, search, aggregate, and lookup tools to agents while preserving request attribution and audit trails.