---
updatedAt: 2026-04-29T12:37:44.000Z
agentTools:
  projectIndex: https://developers.happeo.com/llms.txt
---

# AI Powered keyword search

Keyword & Semantic-based search combining traditional keyword search with vector search. Works best with keywords.

**This is a BETA API -- This API may change unexpectedly.**

This api is only accessible with an Oauth 2.0 client.

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "Public Search API (Beta)",
    "version": "0.1.0",
    "description": "API for the public search functionality, including AI-powered and keyword-based searches.",
    "termsOfService": "https://www.happeo.com/tos",
    "contact": {
      "name": "API Support",
      "email": "support@happeo.com"
    }
  },
  "servers": [
    {
      "url": "https://api.happeo.com/",
      "description": "Production"
    },
    {
      "url": "http://api.unvrs.io/",
      "description": "Staging"
    }
  ],
  "security": [
    {
      "oauth2CustomDomain": [
        "channels:read",
        "pages:read",
        "users:read"
      ]
    },
    {
      "oauth2DefaultDomain": [
        "channels:read",
        "pages:read",
        "users:read"
      ]
    }
  ],
  "components": {
    "securitySchemes": {
      "oauth2CustomDomain": {
        "type": "oauth2",
        "description": "OAuth2 with Authorization Code Flow (custom domain)",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://{YOUR_CUSTOM_DOMAIN}/oauth/authorize",
            "tokenUrl": "https://{YOUR_CUSTOM_DOMAIN}/oauth/token",
            "scopes": {
              "channels:read": "Grants read access to channels data",
              "pages:read": "Grants read access to pages data",
              "users:read": "Grants read access to user data"
            }
          }
        }
      },
      "oauth2DefaultDomain": {
        "type": "oauth2",
        "description": "OAuth2 with Authorization Code Flow",
        "flows": {
          "authorizationCode": {
            "authorizationUrl": "https://app.happeo.com/oauth/authorize",
            "tokenUrl": "https://app.happeo.com/oauth/token",
            "scopes": {
              "channels:read": "Grants read access to channels data",
              "pages:read": "Grants read access to pages data",
              "users:read": "Grants read access to user data"
            }
          }
        }
      }
    }
  },
  "paths": {
    "/beta/search/keyword": {
      "get": {
        "summary": "AI Powered keyword search",
        "operationId": "getKeywordSearchResults",
        "parameters": [
          {
            "in": "query",
            "name": "page",
            "description": "The page number for pagination (0-indexed).",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 0,
              "minimum": 0
            }
          },
          {
            "in": "query",
            "name": "pageSize",
            "description": "The number of items per page.",
            "schema": {
              "type": "integer",
              "format": "int32",
              "default": 10,
              "minimum": 1,
              "maximum": 100
            }
          },
          {
            "in": "query",
            "name": "q",
            "required": true,
            "description": "The search query for keyword search.",
            "schema": {
              "type": "string"
            }
          },
          {
            "in": "query",
            "name": "types",
            "required": true,
            "description": "Comma-separated list of types to search within (for example, `user,page`).",
            "style": "form",
            "explode": false,
            "schema": {
              "type": "string",
              "example": "user,page,post,collection,channel,comment"
            }
          },
          {
            "in": "query",
            "name": "pageGroupId",
            "description": "Page group ID to limit the search within a specific page group.",
            "style": "form",
            "explode": false,
            "schema": {
              "type": "string",
              "example": "9gw4k1bg8hbl7lvrgm"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response with keyword search results.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "took": {
                      "type": "integer",
                      "description": "Time taken to execute the search query in milliseconds."
                    },
                    "total": {
                      "type": "integer",
                      "description": "Total number of results found for the query."
                    },
                    "query": {
                      "type": "string",
                      "description": "The original search query."
                    },
                    "items": {
                      "type": "array",
                      "description": "A list of search result items.",
                      "items": {
                        "type": "object",
                        "required": [
                          "id",
                          "type",
                          "title",
                          "summary",
                          "url",
                          "icon",
                          "score",
                          "content",
                          "metadata"
                        ],
                        "properties": {
                          "id": {
                            "type": "string",
                            "description": "Unique identifier of the search result item."
                          },
                          "type": {
                            "type": "string",
                            "description": "The type of the document (e.g., user, group, page).",
                            "enum": [
                              "user",
                              "group",
                              "page",
                              "collection",
                              "channel",
                              "post",
                              "comment",
                              "unknown"
                            ]
                          },
                          "title": {
                            "type": "string",
                            "description": "The title of the search result item."
                          },
                          "summary": {
                            "type": "string",
                            "description": "A brief summary of the content."
                          },
                          "url": {
                            "type": "string",
                            "description": "The URL to access the full content."
                          },
                          "icon": {
                            "type": "string",
                            "description": "Icon identifier or URL for the content type."
                          },
                          "score": {
                            "type": "number",
                            "format": "float",
                            "description": "Relevance score of the search result."
                          },
                          "content": {
                            "type": "object",
                            "required": [
                              "full",
                              "contentType",
                              "innerHits",
                              "contentLanguage"
                            ],
                            "properties": {
                              "full": {
                                "type": "string",
                                "description": "The full content of the item."
                              },
                              "contentType": {
                                "type": "string",
                                "description": "The format of the content.",
                                "enum": [
                                  "markdown",
                                  "html"
                                ]
                              },
                              "innerHits": {
                                "type": "array",
                                "description": "Array of inner hits with their scores and content snippets.",
                                "items": {
                                  "type": "object",
                                  "properties": {
                                    "score": {
                                      "type": "number",
                                      "format": "float",
                                      "description": "Score of the inner hit."
                                    },
                                    "content": {
                                      "type": "string",
                                      "description": "Content snippet of the inner hit."
                                    }
                                  }
                                }
                              },
                              "contentLanguage": {
                                "type": "string",
                                "description": "Language of the content."
                              }
                            }
                          },
                          "metadata": {
                            "type": "object",
                            "additionalProperties": true,
                            "required": [
                              "hashtags",
                              "createdMillis",
                              "updatedMillis"
                            ],
                            "properties": {
                              "hashtags": {
                                "type": "array",
                                "description": "Array of hashtags associated with the content.",
                                "items": {
                                  "type": "string"
                                }
                              },
                              "createdMillis": {
                                "type": "string",
                                "description": "Creation timestamp in milliseconds."
                              },
                              "updatedMillis": {
                                "type": "string",
                                "description": "Last update timestamp in milliseconds."
                              }
                            }
                          }
                        }
                      }
                    },
                    "filters": {
                      "type": "array",
                      "description": "Available filters and their counts for the search results.",
                      "items": {
                        "type": "object",
                        "required": [
                          "name",
                          "label",
                          "options"
                        ],
                        "properties": {
                          "name": {
                            "type": "string",
                            "description": "The name/identifier of the filter."
                          },
                          "label": {
                            "type": "string",
                            "description": "The display label for the filter."
                          },
                          "options": {
                            "type": "array",
                            "description": "Available options for this filter.",
                            "items": {
                              "type": "object",
                              "required": [
                                "label",
                                "value",
                                "count"
                              ],
                              "properties": {
                                "label": {
                                  "type": "string",
                                  "description": "The display label for the filter option."
                                },
                                "value": {
                                  "type": "string",
                                  "description": "The value to use when applying this filter."
                                },
                                "count": {
                                  "type": "integer",
                                  "description": "The number of results matching this filter option."
                                },
                                "_counts": {
                                  "type": "array",
                                  "description": "Additional count information (optional).",
                                  "items": {
                                    "type": "integer"
                                  }
                                }
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "400": {
            "description": "Bad request, e.g., invalid parameters or missing query.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "message": {
                      "type": "string",
                      "description": "Error message describing the invalid query parameters."
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "Unauthorized - missing or invalid authentication token."
          },
          "500": {
            "description": "Internal Server Error."
          }
        },
        "description": "Keyword & Semantic-based search combining traditional keyword search with vector search. Works best with keywords."
      }
    }
  }
}
```