curl --request POST \
--url https://api.veryfront.com/projects/{project_reference}/knowledge/lookup \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"query": "<string>",
"cursor": "<string>",
"lookup_target": {
"kind": "preview_branch",
"branch_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"limit": 6,
"shard_count": 4,
"shard_index": 1
}
'import requests
url = "https://api.veryfront.com/projects/{project_reference}/knowledge/lookup"
payload = {
"query": "<string>",
"cursor": "<string>",
"lookup_target": {
"kind": "preview_branch",
"branch_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"limit": 6,
"shard_count": 4,
"shard_index": 1
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
query: '<string>',
cursor: '<string>',
lookup_target: {kind: 'preview_branch', branch_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a'},
limit: 6,
shard_count: 4,
shard_index: 1
})
};
fetch('https://api.veryfront.com/projects/{project_reference}/knowledge/lookup', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.veryfront.com/projects/{project_reference}/knowledge/lookup",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'query' => '<string>',
'cursor' => '<string>',
'lookup_target' => [
'kind' => 'preview_branch',
'branch_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'limit' => 6,
'shard_count' => 4,
'shard_index' => 1
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.veryfront.com/projects/{project_reference}/knowledge/lookup"
payload := strings.NewReader("{\n \"query\": \"<string>\",\n \"cursor\": \"<string>\",\n \"lookup_target\": {\n \"kind\": \"preview_branch\",\n \"branch_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"limit\": 6,\n \"shard_count\": 4,\n \"shard_index\": 1\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.veryfront.com/projects/{project_reference}/knowledge/lookup")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"query\": \"<string>\",\n \"cursor\": \"<string>\",\n \"lookup_target\": {\n \"kind\": \"preview_branch\",\n \"branch_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"limit\": 6,\n \"shard_count\": 4,\n \"shard_index\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.veryfront.com/projects/{project_reference}/knowledge/lookup")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"query\": \"<string>\",\n \"cursor\": \"<string>\",\n \"lookup_target\": {\n \"kind\": \"preview_branch\",\n \"branch_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"limit\": 6,\n \"shard_count\": 4,\n \"shard_index\": 1\n}"
response = http.request(request)
puts response.read_body{
"query": "<string>",
"mode": "search",
"data": [
{
"path": "<string>",
"matched_fields": [
"<string>"
],
"frontmatter": [
{
"key": "<string>",
"value": "<string>"
}
]
}
],
"page_info": {
"self": "<string>",
"first": null,
"next": "<string>",
"prev": "<string>"
},
"returned": 1,
"total_matches": 1,
"shard": {
"shard_index": 1,
"shard_count": 2,
"total_items": 1
}
}Search compact knowledge frontmatter across knowledge markdown files with cursor pagination, optional sharding, and explicit preview/environment/release targeting.
curl --request POST \
--url https://api.veryfront.com/projects/{project_reference}/knowledge/lookup \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"query": "<string>",
"cursor": "<string>",
"lookup_target": {
"kind": "preview_branch",
"branch_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"limit": 6,
"shard_count": 4,
"shard_index": 1
}
'import requests
url = "https://api.veryfront.com/projects/{project_reference}/knowledge/lookup"
payload = {
"query": "<string>",
"cursor": "<string>",
"lookup_target": {
"kind": "preview_branch",
"branch_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
},
"limit": 6,
"shard_count": 4,
"shard_index": 1
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
query: '<string>',
cursor: '<string>',
lookup_target: {kind: 'preview_branch', branch_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a'},
limit: 6,
shard_count: 4,
shard_index: 1
})
};
fetch('https://api.veryfront.com/projects/{project_reference}/knowledge/lookup', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.veryfront.com/projects/{project_reference}/knowledge/lookup",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'query' => '<string>',
'cursor' => '<string>',
'lookup_target' => [
'kind' => 'preview_branch',
'branch_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'
],
'limit' => 6,
'shard_count' => 4,
'shard_index' => 1
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.veryfront.com/projects/{project_reference}/knowledge/lookup"
payload := strings.NewReader("{\n \"query\": \"<string>\",\n \"cursor\": \"<string>\",\n \"lookup_target\": {\n \"kind\": \"preview_branch\",\n \"branch_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"limit\": 6,\n \"shard_count\": 4,\n \"shard_index\": 1\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.veryfront.com/projects/{project_reference}/knowledge/lookup")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"query\": \"<string>\",\n \"cursor\": \"<string>\",\n \"lookup_target\": {\n \"kind\": \"preview_branch\",\n \"branch_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"limit\": 6,\n \"shard_count\": 4,\n \"shard_index\": 1\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.veryfront.com/projects/{project_reference}/knowledge/lookup")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"query\": \"<string>\",\n \"cursor\": \"<string>\",\n \"lookup_target\": {\n \"kind\": \"preview_branch\",\n \"branch_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n },\n \"limit\": 6,\n \"shard_count\": 4,\n \"shard_index\": 1\n}"
response = http.request(request)
puts response.read_body{
"query": "<string>",
"mode": "search",
"data": [
{
"path": "<string>",
"matched_fields": [
"<string>"
],
"frontmatter": [
{
"key": "<string>",
"value": "<string>"
}
]
}
],
"page_info": {
"self": "<string>",
"first": null,
"next": "<string>",
"prev": "<string>"
},
"returned": 1,
"total_matches": 1,
"shard": {
"shard_index": 1,
"shard_count": 2,
"total_items": 1
}
}Authorizations
Use a JWT bearer token or a Veryfront API key in the Authorization header.
Path Parameters
Project ID or slug.
Body
Text to match against knowledge frontmatter. On the first request, provide query without cursor.
1 - 500Opaque pagination token. Omit on the first request. To continue, repeat the same original query and pass page_info.next from the previous response as cursor.
1 - 13334Optional. Omit to search the current branch (the default). Only set this to target a specific deployed environment or release.
- Option 1
- Option 2
- Option 3
Show child attributes
Show child attributes
Maximum number of results to return.
1 <= x <= 12Provide the shard count.
1 <= x <= 8Provide the shard index.
x >= 0Response
Knowledge lookup results.
Query string associated with this result.
The mode associated with this tool result.
search, browse Primary result records returned by the tool.
Show child attributes
Show child attributes
Pagination cursor values for traversing the result set.
Show child attributes
Show child attributes
The returned associated with this tool result.
x >= 0Total number of matches found by the tool.
x >= 0Structured shard details associated with this tool result.
Show child attributes
Show child attributes