Tutorials & Examples
On Express.js

Get Started

Tutorial coming soon but in the meantime, you can check out the express js codesandbox example (opens in a new tab).

and below is the code for the express js middleware example.

var express = require("express");
var router = express.Router();
var Client = require("@searchkit/api").default;
const apiClient = Client({
  connection: {
    apiKey: "<API_KEY>",
  search_settings: {
    highlight_attributes: ["title", "actors"],
    search_attributes: ["title", "actors"],
    result_attributes: ["title", "actors", "poster"],
    facet_attributes: [
      { attribute: "actors", field: "actors.keyword" },
      { attribute: "imdbrating", type: "numeric" },
      { attribute: "metascore", type: "numeric" },
router.post("/", async function (req, res) {
  const response = await apiClient.handleRequest(req.body);
module.exports = router;