So here's a code sample of what I'm trying to do i...
# community-help
s
So here's a code sample of what I'm trying to do in my cloud function - I think maybe I have the endpoint syntax wrong.
Copy code
const response = await <http://axios.post|axios.post>(
      `${typesenseProtocol}://${typesenseHost}:${typesensePort}/collections/userTags/documents/search`,
      {
        q: searchText.toLowerCase(), // empty string allowed
        query_by: "tag,category",
        filter_by: `category:${category}`,
        prefix: true,
        infix: "fallback",
        limit: 10,
      },
      {
        headers: {
          "X-TYPESENSE-API-KEY": typesenseApiKey, // Use the secret API key
        },
      },
    );