SL
SemiLayer · Live Demo
ask anything. no backend.

Typed query

Ask in shape — filters, orderBy, limit. The same lens, same key, same latency — but now you're driving the table directly. Useful for browse grids, admin views, structured pipelines.

IDCodeNameBrandCategoryTagsPrice

The entire integration

One publishable key. That's it — copy the call into curl, any fetch, any HTTP client. The key carries scope.

POST https://api.semilayer.com/v1/query/food_products
Authorization: Bearer pk_...
Content-Type: application/json

{
  "where": { "brand": "Meijer", "price_cents": { "$lt": 500 } },
  "orderBy": { "field": "price_cents", "dir": "asc" },
  "limit": 10
}

What the layer is doing

Somewhere behind this page a food_products lens was declared. SemiLayer took care of understanding it, indexing it, and keeping it fresh. You get one endpoint to ask in words, another to ask in shape, a third to compose a live feed. The data never moves.

// one lens, every surface on this page.
food_products: {
  facets: {
    search:  { fields: ['name', 'description', 'brand', 'tags'] },
    similar: { fields: ['name', 'description', 'brand', 'tags'] },
    feed: {
      discover:  { /* similarity + recency */ },
      latest:    { /* pure recency */ },
      relatedTo: { /* recordVector seed */ },
    },
  },
  rules: {
    query:   'public',
    search:  'public',
    similar: 'public',
    feed:    { discover: 'public', latest: 'public', relatedTo: 'public' },
  },
}