Full-text search documents
AuthorizationBearer <token>
In: header
Query Parameters
q?string
Search query
projectId?string
Format
"uuid"documentTypeId?string
Format
"uuid"sortBy?string
Default
"relevance"Value in
"relevance" | "date" | "title" | "size"sortOrder?string
Default
"desc"Value in
"asc" | "desc"Response Body
curl -X GET "http://localhost:3000/api/search/documents?q=string&projectId=497f6eca-6276-4993-bfeb-53cbbbba6f08&documentTypeId=497f6eca-6276-4993-bfeb-53cbbbba6f08&sortBy=relevance&sortOrder=asc"fetch("http://localhost:3000/api/search/documents?q=string&projectId=497f6eca-6276-4993-bfeb-53cbbbba6f08&documentTypeId=497f6eca-6276-4993-bfeb-53cbbbba6f08&sortBy=relevance&sortOrder=asc")package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "http://localhost:3000/api/search/documents?q=string&projectId=497f6eca-6276-4993-bfeb-53cbbbba6f08&documentTypeId=497f6eca-6276-4993-bfeb-53cbbbba6f08&sortBy=relevance&sortOrder=asc"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "http://localhost:3000/api/search/documents?q=string&projectId=497f6eca-6276-4993-bfeb-53cbbbba6f08&documentTypeId=497f6eca-6276-4993-bfeb-53cbbbba6f08&sortBy=relevance&sortOrder=asc"
response = requests.request("GET", url)
print(response.text){
"documents": [
{
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
"projectId": "5a8591dd-4039-49df-9202-96385ba3eff8",
"documentTypeId": "50553e40-12c2-4419-b582-c37b1f8e3bec",
"title": "string",
"description": "string",
"fileName": "string",
"fileSize": 0,
"mimeType": "string",
"currentVersion": 0,
"status": "draft",
"tags": [
"string"
],
"metadata": {},
"uploadedBy": "1e2815fd-75c7-4289-86d5-2503daeb59b8",
"createdAt": "2019-08-24T14:15:22Z",
"updatedAt": "2019-08-24T14:15:22Z",
"relevanceScore": 0,
"highlights": {
"title": "string",
"description": "string"
}
}
],
"pagination": {
"page": 0,
"limit": 0,
"total": 0,
"totalPages": 0
},
"meta": {
"executionTimeMs": 0
}
}