(deprecated since 23.1)Get Materialized view by id.
curl --request GET \
--url http://10.2.4.166:8080/composer/api/materialized-views/{id} \
--header 'Authorization: Basic <encoded-value>'import requests
url = "http://10.2.4.166:8080/composer/api/materialized-views/{id}"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('http://10.2.4.166:8080/composer/api/materialized-views/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "8080",
CURLOPT_URL => "http://10.2.4.166:8080/composer/api/materialized-views/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>"
],
]);
$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 := "http://10.2.4.166:8080/composer/api/materialized-views/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("http://10.2.4.166:8080/composer/api/materialized-views/{id}")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("http://10.2.4.166:8080/composer/api/materialized-views/{id}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body{
"name": "<string>",
"description": "<string>",
"enabled": true,
"definition": {
"type": "AGG",
"filters": [
{
"path": {
"name": "<string>"
},
"operation": "EQUALS",
"value": "<unknown>"
}
],
"sourceId": "<string>",
"aggregations": [
{
"type": "TERMS",
"field": {
"name": "<string>"
}
}
],
"metrics": [
{
"type": "COUNT",
"rollup": true,
"formulaName": "<string>",
"formula": "<string>"
}
]
},
"storageSettings": {
"targetStorage": {
"connectionId": "<string>",
"schemas": [
"<string>"
],
"collection": "<string>",
"collectionParams": {}
},
"fieldMappings": [
{
"targetFieldName": "<string>",
"sourceFieldName": "<string>",
"sourceMetric": {
"type": "COUNT",
"rollup": true,
"formulaName": "<string>",
"formula": "<string>"
},
"sourceAggregation": {
"type": "TERMS",
"field": {
"name": "<string>"
}
}
}
]
},
"id": "<string>",
"referencedSourceIds": [
"<string>"
],
"definitionQuery": "<string>"
}(deprecated since 23.1)Get Materialized view by id.
deprecated
(deprecated since 23.1)Get Materialized view by id.
curl --request GET \
--url http://10.2.4.166:8080/composer/api/materialized-views/{id} \
--header 'Authorization: Basic <encoded-value>'import requests
url = "http://10.2.4.166:8080/composer/api/materialized-views/{id}"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('http://10.2.4.166:8080/composer/api/materialized-views/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "8080",
CURLOPT_URL => "http://10.2.4.166:8080/composer/api/materialized-views/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>"
],
]);
$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 := "http://10.2.4.166:8080/composer/api/materialized-views/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("http://10.2.4.166:8080/composer/api/materialized-views/{id}")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("http://10.2.4.166:8080/composer/api/materialized-views/{id}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body{
"name": "<string>",
"description": "<string>",
"enabled": true,
"definition": {
"type": "AGG",
"filters": [
{
"path": {
"name": "<string>"
},
"operation": "EQUALS",
"value": "<unknown>"
}
],
"sourceId": "<string>",
"aggregations": [
{
"type": "TERMS",
"field": {
"name": "<string>"
}
}
],
"metrics": [
{
"type": "COUNT",
"rollup": true,
"formulaName": "<string>",
"formula": "<string>"
}
]
},
"storageSettings": {
"targetStorage": {
"connectionId": "<string>",
"schemas": [
"<string>"
],
"collection": "<string>",
"collectionParams": {}
},
"fieldMappings": [
{
"targetFieldName": "<string>",
"sourceFieldName": "<string>",
"sourceMetric": {
"type": "COUNT",
"rollup": true,
"formulaName": "<string>",
"formula": "<string>"
},
"sourceAggregation": {
"type": "TERMS",
"field": {
"name": "<string>"
}
}
}
]
},
"id": "<string>",
"referencedSourceIds": [
"<string>"
],
"definitionQuery": "<string>"
}Authorizations
HTTP Basic authentication using global administrator credentials (username and password).
Path Parameters
Response
200 - application/vnd.composer.v3+json
OK
Materialized View
Structure that defines the data stored in a Materialized View.
- Option 1
- Option 2
Show child attributes
Show child attributes
Storage settings for Materialized View, required to use external data storage. If not specified, data will be automatically stored internally.
Show child attributes
Show child attributes
Sources that can be matched by this Materialized View.
SQL query that defines this Materialized View.
Was this page helpful?