Query
Query note properties
POST-only property aggregation (filters, sort, group_by, aggregate). The list path is GET /v1/notes?filter= (AIP-160). This route is not a tags or daily-notes endpoint.
POST
/
v1
/
query
Query note properties
curl --request POST \
--url https://api.elanotes.com/v1/query \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"filters": [],
"group_by": "<string>",
"limit": 50
}
'import requests
url = "https://api.elanotes.com/v1/query"
payload = {
"filters": [],
"group_by": "<string>",
"limit": 50
}
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({filters: [], group_by: '<string>', limit: 50})
};
fetch('https://api.elanotes.com/v1/query', 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.elanotes.com/v1/query",
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([
'filters' => [
],
'group_by' => '<string>',
'limit' => 50
]),
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.elanotes.com/v1/query"
payload := strings.NewReader("{\n \"filters\": [],\n \"group_by\": \"<string>\",\n \"limit\": 50\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.elanotes.com/v1/query")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"filters\": [],\n \"group_by\": \"<string>\",\n \"limit\": 50\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.elanotes.com/v1/query")
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 \"filters\": [],\n \"group_by\": \"<string>\",\n \"limit\": 50\n}"
response = http.request(request)
puts response.read_body{
"coverage": {
"excluded_folders": [
"<string>"
],
"notes_searched": 0,
"property_coverage": {},
"reason": "<string>"
},
"notes": [
{
"folder": "<string>",
"properties": {},
"slug": "<string>",
"title": "<string>"
}
],
"total_matched": 0,
"aggregate": {
"considered": 0,
"op": "count",
"property": "<string>",
"value": 123
},
"groups": [
{
"count": 0,
"key": "<string>"
}
]
}{
"details": [
{
"@type": "<string>"
}
],
"error": "<string>",
"help": "<string>",
"hint": "<string>",
"message": "<string>",
"reason": "<string>",
"requestId": "<string>",
"statusCode": 0
}{
"details": [
{
"@type": "<string>"
}
],
"error": "<string>",
"help": "<string>",
"hint": "<string>",
"message": "<string>",
"reason": "<string>",
"requestId": "<string>",
"statusCode": 0
}Authorizations
Static bearer, WorkOS JWT, or open local when AUTH_REQUIRED is off and no static tokens are set. The token selects the vault; paths do not include vault_id.
Body
application/json
⌘I
Query note properties
curl --request POST \
--url https://api.elanotes.com/v1/query \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"filters": [],
"group_by": "<string>",
"limit": 50
}
'import requests
url = "https://api.elanotes.com/v1/query"
payload = {
"filters": [],
"group_by": "<string>",
"limit": 50
}
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({filters: [], group_by: '<string>', limit: 50})
};
fetch('https://api.elanotes.com/v1/query', 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.elanotes.com/v1/query",
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([
'filters' => [
],
'group_by' => '<string>',
'limit' => 50
]),
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.elanotes.com/v1/query"
payload := strings.NewReader("{\n \"filters\": [],\n \"group_by\": \"<string>\",\n \"limit\": 50\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.elanotes.com/v1/query")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"filters\": [],\n \"group_by\": \"<string>\",\n \"limit\": 50\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.elanotes.com/v1/query")
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 \"filters\": [],\n \"group_by\": \"<string>\",\n \"limit\": 50\n}"
response = http.request(request)
puts response.read_body{
"coverage": {
"excluded_folders": [
"<string>"
],
"notes_searched": 0,
"property_coverage": {},
"reason": "<string>"
},
"notes": [
{
"folder": "<string>",
"properties": {},
"slug": "<string>",
"title": "<string>"
}
],
"total_matched": 0,
"aggregate": {
"considered": 0,
"op": "count",
"property": "<string>",
"value": 123
},
"groups": [
{
"count": 0,
"key": "<string>"
}
]
}{
"details": [
{
"@type": "<string>"
}
],
"error": "<string>",
"help": "<string>",
"hint": "<string>",
"message": "<string>",
"reason": "<string>",
"requestId": "<string>",
"statusCode": 0
}{
"details": [
{
"@type": "<string>"
}
],
"error": "<string>",
"help": "<string>",
"hint": "<string>",
"message": "<string>",
"reason": "<string>",
"requestId": "<string>",
"statusCode": 0
}
