List Filter Definitions
curl --request GET \
--url https://reporter.sandbox.lerian.net/v1/templates/filters \
--header 'X-Organization-id: <x-organization-id>'import requests
url = "https://reporter.sandbox.lerian.net/v1/templates/filters"
headers = {"X-Organization-id": "<x-organization-id>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Organization-id': '<x-organization-id>'}};
fetch('https://reporter.sandbox.lerian.net/v1/templates/filters', 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://reporter.sandbox.lerian.net/v1/templates/filters",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Organization-id: <x-organization-id>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://reporter.sandbox.lerian.net/v1/templates/filters"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Organization-id", "<x-organization-id>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://reporter.sandbox.lerian.net/v1/templates/filters")
.header("X-Organization-id", "<x-organization-id>")
.asString();require 'uri'
require 'net/http'
url = URI("https://reporter.sandbox.lerian.net/v1/templates/filters")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Organization-id"] = '<x-organization-id>'
response = http.request(request)
puts response.read_body{
"filters": [
{
"name": "date",
"description": "Formats a date value using the given layout.",
"example": "{{ dueDate|date:\"2006-01-02\" }}",
"args": [
"layout"
]
},
{
"name": "default",
"description": "Returns a fallback value when the input is empty.",
"example": "{{ description|default:\"N/A\" }}",
"args": [
"fallback"
]
}
]
}List Filter Definitions
Use this endpoint to retrieve the filters available for use inside templates, including each filter’s arguments and a usage example. Filters transform field values when a report is rendered.
GET
/
v1
/
templates
/
filters
List Filter Definitions
curl --request GET \
--url https://reporter.sandbox.lerian.net/v1/templates/filters \
--header 'X-Organization-id: <x-organization-id>'import requests
url = "https://reporter.sandbox.lerian.net/v1/templates/filters"
headers = {"X-Organization-id": "<x-organization-id>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-Organization-id': '<x-organization-id>'}};
fetch('https://reporter.sandbox.lerian.net/v1/templates/filters', 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://reporter.sandbox.lerian.net/v1/templates/filters",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-Organization-id: <x-organization-id>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://reporter.sandbox.lerian.net/v1/templates/filters"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Organization-id", "<x-organization-id>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://reporter.sandbox.lerian.net/v1/templates/filters")
.header("X-Organization-id", "<x-organization-id>")
.asString();require 'uri'
require 'net/http'
url = URI("https://reporter.sandbox.lerian.net/v1/templates/filters")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Organization-id"] = '<x-organization-id>'
response = http.request(request)
puts response.read_body{
"filters": [
{
"name": "date",
"description": "Formats a date value using the given layout.",
"example": "{{ dueDate|date:\"2006-01-02\" }}",
"args": [
"layout"
]
},
{
"name": "default",
"description": "Returns a fallback value when the input is empty.",
"example": "{{ description|default:\"N/A\" }}",
"args": [
"fallback"
]
}
]
}Headers
The authorization token in the 'Bearer ' format.
Important: This header is required if your environment has Access Manager enabled. For more information, refer to the Access Manager documentation.
The unique identifier of the Organization associated with the request.
Response
200 - application/json
The list of available filter definitions.
Available filter definitions.
Show child attributes
Show child attributes
Was this page helpful?
⌘I

