curl --request POST \
--url https://api.extole.io/v6/report-types/{id}/schema \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"parameters": {
"parameters_key": "parameters_key"
}
}
'import requests
url = "https://api.extole.io/v6/report-types/{id}/schema"
payload = { "parameters": { "parameters_key": "parameters_key" } }
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({parameters: {parameters_key: 'parameters_key'}})
};
fetch('https://api.extole.io/v6/report-types/{id}/schema', 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.extole.io/v6/report-types/{id}/schema",
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([
'parameters' => [
'parameters_key' => 'parameters_key'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"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.extole.io/v6/report-types/{id}/schema"
payload := strings.NewReader("{\n \"parameters\": {\n \"parameters_key\": \"parameters_key\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
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.extole.io/v6/report-types/{id}/schema")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"parameters\": {\n \"parameters_key\": \"parameters_key\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.extole.io/v6/report-types/{id}/schema")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"parameters\": {\n \"parameters_key\": \"parameters_key\"\n }\n}"
response = http.request(request)
puts response.read_body{
"columns": [
{
"name": "<string>",
"note": "<string>",
"sample_value": "<string>"
}
],
"context_parameters": {},
"report_type_id": "<string>",
"sample_rows": [
{}
]
}Get report type schema for a context
Returns the schema a report type produces for the supplied report parameter values - the ordered columns or representative sample_rows in its output. Persists nothing. The response describes the output the report emits when run with those same values, so a client can learn its output shape before running it. Only parameters the report type contextualizes its schema on are accepted, and supplying any other is rejected. The response echoes the effective parameter values used to resolve the schema. Parameters left out resolve to the report type’s own defaults rather than making the answer partial. When the supplied values select nothing the report would summarize, the report emits no rows, so sample_rows is empty while context_parameters still echoes what the schema resolved against.
curl --request POST \
--url https://api.extole.io/v6/report-types/{id}/schema \
--header 'Authorization: <api-key>' \
--header 'Content-Type: application/json' \
--data '
{
"parameters": {
"parameters_key": "parameters_key"
}
}
'import requests
url = "https://api.extole.io/v6/report-types/{id}/schema"
payload = { "parameters": { "parameters_key": "parameters_key" } }
headers = {
"Authorization": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({parameters: {parameters_key: 'parameters_key'}})
};
fetch('https://api.extole.io/v6/report-types/{id}/schema', 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.extole.io/v6/report-types/{id}/schema",
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([
'parameters' => [
'parameters_key' => 'parameters_key'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"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.extole.io/v6/report-types/{id}/schema"
payload := strings.NewReader("{\n \"parameters\": {\n \"parameters_key\": \"parameters_key\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "<api-key>")
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.extole.io/v6/report-types/{id}/schema")
.header("Authorization", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"parameters\": {\n \"parameters_key\": \"parameters_key\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.extole.io/v6/report-types/{id}/schema")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"parameters\": {\n \"parameters_key\": \"parameters_key\"\n }\n}"
response = http.request(request)
puts response.read_body{
"columns": [
{
"name": "<string>",
"note": "<string>",
"sample_value": "<string>"
}
],
"context_parameters": {},
"report_type_id": "<string>",
"sample_rows": [
{}
]
}Authorizations
Path Parameters
The Extole unique report type identifier.
Body
Report parameter values to resolve the schema against, keyed by parameter name. Only parameters the report type contextualizes its schema on are accepted. A parameter left out resolves to the report type's declared default. A supplied value, including a blank value, is used as supplied. An empty map resolves the schema exactly as the parameterless read does. Pass these same values to POST /v4/reports to run the report that emits the returned columns.
Show child attributes
Show child attributes
Response
Schema the report type produces for the supplied context, with output columns or representative nested JSON rows, alongside the parameter values it was resolved against.
Columns the report type produces, in output order.
Show child attributes
Show child attributes
Report parameters this schema was resolved against, keyed by parameter name. Each one can change the schema; supply report parameter values in the POST request body to resolve the schema against a different context. A value is what the caller supplied, otherwise the report type's declared default; parameters with neither are absent, and leaving one out resolves the schema against the report type's own default behavior rather than making the answer partial. Run the report with these same parameter values to get these same columns and representative rows. Empty for report types whose schema does not depend on context.
Show child attributes
Show child attributes
Id of the report type this schema belongs to. Pass it to GET /v6/report-types/{id}/schema to fetch this schema on its own.
Representative nested JSON output row shapes for this context. These are mock shapes, not report data and not a JSON Schema.
