curl --request POST \
--url http://10.2.4.166:8080/composer/api/sources/data-entities/describe \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/vnd.composer.v3+json' \
--data '
{
"id": "data_entity_id",
"name": "Data Entity name",
"nativeFields": [
{
"origin": {
"derivedOrigin": {
"expression": "sales * 100",
"calendarId": "<string>",
"referencedFieldNames": [
"<string>"
]
}
},
"name": "field_name",
"label": "Field Label",
"visible": true,
"format": {
"time": {
"timeZone": "UTC",
"options": {
"hour12": true
}
}
},
"statistics": {
"override": {
"min": 123,
"max": 123,
"distinctValues": [
"<unknown>"
]
},
"cacheEnabled": true,
"refreshable": true,
"cardinality": 123
},
"facetFiltering": {
"enabled": true,
"order": 2
},
"disabledCapabilities": [
"<string>"
],
"fieldMetadata": {},
"rawFormatSupportTimeGroup": true,
"fieldName": "<string>",
"originalFieldName": "<string>"
}
],
"forbiddenFeatures": [
"<string>"
],
"auxiliary": true
}
'import requests
url = "http://10.2.4.166:8080/composer/api/sources/data-entities/describe"
payload = {
"id": "data_entity_id",
"name": "Data Entity name",
"nativeFields": [
{
"origin": { "derivedOrigin": {
"expression": "sales * 100",
"calendarId": "<string>",
"referencedFieldNames": ["<string>"]
} },
"name": "field_name",
"label": "Field Label",
"visible": True,
"format": { "time": {
"timeZone": "UTC",
"options": { "hour12": True }
} },
"statistics": {
"override": {
"min": 123,
"max": 123,
"distinctValues": ["<unknown>"]
},
"cacheEnabled": True,
"refreshable": True,
"cardinality": 123
},
"facetFiltering": {
"enabled": True,
"order": 2
},
"disabledCapabilities": ["<string>"],
"fieldMetadata": {},
"rawFormatSupportTimeGroup": True,
"fieldName": "<string>",
"originalFieldName": "<string>"
}
],
"forbiddenFeatures": ["<string>"],
"auxiliary": True
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/vnd.composer.v3+json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Basic <encoded-value>',
'Content-Type': 'application/vnd.composer.v3+json'
},
body: JSON.stringify({
id: 'data_entity_id',
name: 'Data Entity name',
nativeFields: [
{
origin: {
derivedOrigin: {
expression: 'sales * 100',
calendarId: '<string>',
referencedFieldNames: ['<string>']
}
},
name: 'field_name',
label: 'Field Label',
visible: true,
format: {time: {timeZone: 'UTC', options: {hour12: true}}},
statistics: {
override: {min: 123, max: 123, distinctValues: ['<unknown>']},
cacheEnabled: true,
refreshable: true,
cardinality: 123
},
facetFiltering: {enabled: true, order: 2},
disabledCapabilities: ['<string>'],
fieldMetadata: {},
rawFormatSupportTimeGroup: true,
fieldName: '<string>',
originalFieldName: '<string>'
}
],
forbiddenFeatures: ['<string>'],
auxiliary: true
})
};
fetch('http://10.2.4.166:8080/composer/api/sources/data-entities/describe', 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/sources/data-entities/describe",
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([
'id' => 'data_entity_id',
'name' => 'Data Entity name',
'nativeFields' => [
[
'origin' => [
'derivedOrigin' => [
'expression' => 'sales * 100',
'calendarId' => '<string>',
'referencedFieldNames' => [
'<string>'
]
]
],
'name' => 'field_name',
'label' => 'Field Label',
'visible' => true,
'format' => [
'time' => [
'timeZone' => 'UTC',
'options' => [
'hour12' => true
]
]
],
'statistics' => [
'override' => [
'min' => 123,
'max' => 123,
'distinctValues' => [
'<unknown>'
]
],
'cacheEnabled' => true,
'refreshable' => true,
'cardinality' => 123
],
'facetFiltering' => [
'enabled' => true,
'order' => 2
],
'disabledCapabilities' => [
'<string>'
],
'fieldMetadata' => [
],
'rawFormatSupportTimeGroup' => true,
'fieldName' => '<string>',
'originalFieldName' => '<string>'
]
],
'forbiddenFeatures' => [
'<string>'
],
'auxiliary' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/vnd.composer.v3+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 := "http://10.2.4.166:8080/composer/api/sources/data-entities/describe"
payload := strings.NewReader("{\n \"id\": \"data_entity_id\",\n \"name\": \"Data Entity name\",\n \"nativeFields\": [\n {\n \"origin\": {\n \"derivedOrigin\": {\n \"expression\": \"sales * 100\",\n \"calendarId\": \"<string>\",\n \"referencedFieldNames\": [\n \"<string>\"\n ]\n }\n },\n \"name\": \"field_name\",\n \"label\": \"Field Label\",\n \"visible\": true,\n \"format\": {\n \"time\": {\n \"timeZone\": \"UTC\",\n \"options\": {\n \"hour12\": true\n }\n }\n },\n \"statistics\": {\n \"override\": {\n \"min\": 123,\n \"max\": 123,\n \"distinctValues\": [\n \"<unknown>\"\n ]\n },\n \"cacheEnabled\": true,\n \"refreshable\": true,\n \"cardinality\": 123\n },\n \"facetFiltering\": {\n \"enabled\": true,\n \"order\": 2\n },\n \"disabledCapabilities\": [\n \"<string>\"\n ],\n \"fieldMetadata\": {},\n \"rawFormatSupportTimeGroup\": true,\n \"fieldName\": \"<string>\",\n \"originalFieldName\": \"<string>\"\n }\n ],\n \"forbiddenFeatures\": [\n \"<string>\"\n ],\n \"auxiliary\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/vnd.composer.v3+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://10.2.4.166:8080/composer/api/sources/data-entities/describe")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/vnd.composer.v3+json")
.body("{\n \"id\": \"data_entity_id\",\n \"name\": \"Data Entity name\",\n \"nativeFields\": [\n {\n \"origin\": {\n \"derivedOrigin\": {\n \"expression\": \"sales * 100\",\n \"calendarId\": \"<string>\",\n \"referencedFieldNames\": [\n \"<string>\"\n ]\n }\n },\n \"name\": \"field_name\",\n \"label\": \"Field Label\",\n \"visible\": true,\n \"format\": {\n \"time\": {\n \"timeZone\": \"UTC\",\n \"options\": {\n \"hour12\": true\n }\n }\n },\n \"statistics\": {\n \"override\": {\n \"min\": 123,\n \"max\": 123,\n \"distinctValues\": [\n \"<unknown>\"\n ]\n },\n \"cacheEnabled\": true,\n \"refreshable\": true,\n \"cardinality\": 123\n },\n \"facetFiltering\": {\n \"enabled\": true,\n \"order\": 2\n },\n \"disabledCapabilities\": [\n \"<string>\"\n ],\n \"fieldMetadata\": {},\n \"rawFormatSupportTimeGroup\": true,\n \"fieldName\": \"<string>\",\n \"originalFieldName\": \"<string>\"\n }\n ],\n \"forbiddenFeatures\": [\n \"<string>\"\n ],\n \"auxiliary\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://10.2.4.166:8080/composer/api/sources/data-entities/describe")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/vnd.composer.v3+json'
request.body = "{\n \"id\": \"data_entity_id\",\n \"name\": \"Data Entity name\",\n \"nativeFields\": [\n {\n \"origin\": {\n \"derivedOrigin\": {\n \"expression\": \"sales * 100\",\n \"calendarId\": \"<string>\",\n \"referencedFieldNames\": [\n \"<string>\"\n ]\n }\n },\n \"name\": \"field_name\",\n \"label\": \"Field Label\",\n \"visible\": true,\n \"format\": {\n \"time\": {\n \"timeZone\": \"UTC\",\n \"options\": {\n \"hour12\": true\n }\n }\n },\n \"statistics\": {\n \"override\": {\n \"min\": 123,\n \"max\": 123,\n \"distinctValues\": [\n \"<unknown>\"\n ]\n },\n \"cacheEnabled\": true,\n \"refreshable\": true,\n \"cardinality\": 123\n },\n \"facetFiltering\": {\n \"enabled\": true,\n \"order\": 2\n },\n \"disabledCapabilities\": [\n \"<string>\"\n ],\n \"fieldMetadata\": {},\n \"rawFormatSupportTimeGroup\": true,\n \"fieldName\": \"<string>\",\n \"originalFieldName\": \"<string>\"\n }\n ],\n \"forbiddenFeatures\": [\n \"<string>\"\n ],\n \"auxiliary\": true\n}"
response = http.request(request)
puts response.read_body{
"content": [
{
"type": "ATTRIBUTE",
"originalFieldName": "<string>",
"name": "<string>",
"label": "<string>"
}
]
}{
"error": "<string>",
"details": "<string>",
"message": "<string>",
"path": "<string>",
"status": "<string>",
"code": "<string>",
"errorCode": "<string>",
"timestamp": "<string>",
"problems": [
{
"name": "<string>",
"message": "<string>",
"level": "ERROR",
"dependencies": {}
}
]
}{
"timestamp": "2023-11-07T05:31:56Z",
"status": 123,
"error": "<string>",
"message": "<string>",
"path": "<string>"
}{
"error": "<string>",
"details": "<string>",
"message": "<string>",
"path": "<string>",
"status": "<string>",
"code": "<string>",
"errorCode": "<string>",
"timestamp": "<string>",
"problems": [
{
"name": "<string>",
"message": "<string>",
"level": "ERROR",
"dependencies": {}
}
]
}{
"error": "<string>",
"details": "<string>",
"message": "<string>",
"path": "<string>",
"status": "<string>",
"code": "<string>",
"errorCode": "<string>",
"timestamp": "<string>",
"problems": [
{
"name": "<string>",
"message": "<string>",
"level": "ERROR",
"dependencies": {}
}
]
}Returns the details of all data entity fields
Requires READ permission on the connection and upload that is used in the data entity
curl --request POST \
--url http://10.2.4.166:8080/composer/api/sources/data-entities/describe \
--header 'Authorization: Basic <encoded-value>' \
--header 'Content-Type: application/vnd.composer.v3+json' \
--data '
{
"id": "data_entity_id",
"name": "Data Entity name",
"nativeFields": [
{
"origin": {
"derivedOrigin": {
"expression": "sales * 100",
"calendarId": "<string>",
"referencedFieldNames": [
"<string>"
]
}
},
"name": "field_name",
"label": "Field Label",
"visible": true,
"format": {
"time": {
"timeZone": "UTC",
"options": {
"hour12": true
}
}
},
"statistics": {
"override": {
"min": 123,
"max": 123,
"distinctValues": [
"<unknown>"
]
},
"cacheEnabled": true,
"refreshable": true,
"cardinality": 123
},
"facetFiltering": {
"enabled": true,
"order": 2
},
"disabledCapabilities": [
"<string>"
],
"fieldMetadata": {},
"rawFormatSupportTimeGroup": true,
"fieldName": "<string>",
"originalFieldName": "<string>"
}
],
"forbiddenFeatures": [
"<string>"
],
"auxiliary": true
}
'import requests
url = "http://10.2.4.166:8080/composer/api/sources/data-entities/describe"
payload = {
"id": "data_entity_id",
"name": "Data Entity name",
"nativeFields": [
{
"origin": { "derivedOrigin": {
"expression": "sales * 100",
"calendarId": "<string>",
"referencedFieldNames": ["<string>"]
} },
"name": "field_name",
"label": "Field Label",
"visible": True,
"format": { "time": {
"timeZone": "UTC",
"options": { "hour12": True }
} },
"statistics": {
"override": {
"min": 123,
"max": 123,
"distinctValues": ["<unknown>"]
},
"cacheEnabled": True,
"refreshable": True,
"cardinality": 123
},
"facetFiltering": {
"enabled": True,
"order": 2
},
"disabledCapabilities": ["<string>"],
"fieldMetadata": {},
"rawFormatSupportTimeGroup": True,
"fieldName": "<string>",
"originalFieldName": "<string>"
}
],
"forbiddenFeatures": ["<string>"],
"auxiliary": True
}
headers = {
"Authorization": "Basic <encoded-value>",
"Content-Type": "application/vnd.composer.v3+json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
Authorization: 'Basic <encoded-value>',
'Content-Type': 'application/vnd.composer.v3+json'
},
body: JSON.stringify({
id: 'data_entity_id',
name: 'Data Entity name',
nativeFields: [
{
origin: {
derivedOrigin: {
expression: 'sales * 100',
calendarId: '<string>',
referencedFieldNames: ['<string>']
}
},
name: 'field_name',
label: 'Field Label',
visible: true,
format: {time: {timeZone: 'UTC', options: {hour12: true}}},
statistics: {
override: {min: 123, max: 123, distinctValues: ['<unknown>']},
cacheEnabled: true,
refreshable: true,
cardinality: 123
},
facetFiltering: {enabled: true, order: 2},
disabledCapabilities: ['<string>'],
fieldMetadata: {},
rawFormatSupportTimeGroup: true,
fieldName: '<string>',
originalFieldName: '<string>'
}
],
forbiddenFeatures: ['<string>'],
auxiliary: true
})
};
fetch('http://10.2.4.166:8080/composer/api/sources/data-entities/describe', 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/sources/data-entities/describe",
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([
'id' => 'data_entity_id',
'name' => 'Data Entity name',
'nativeFields' => [
[
'origin' => [
'derivedOrigin' => [
'expression' => 'sales * 100',
'calendarId' => '<string>',
'referencedFieldNames' => [
'<string>'
]
]
],
'name' => 'field_name',
'label' => 'Field Label',
'visible' => true,
'format' => [
'time' => [
'timeZone' => 'UTC',
'options' => [
'hour12' => true
]
]
],
'statistics' => [
'override' => [
'min' => 123,
'max' => 123,
'distinctValues' => [
'<unknown>'
]
],
'cacheEnabled' => true,
'refreshable' => true,
'cardinality' => 123
],
'facetFiltering' => [
'enabled' => true,
'order' => 2
],
'disabledCapabilities' => [
'<string>'
],
'fieldMetadata' => [
],
'rawFormatSupportTimeGroup' => true,
'fieldName' => '<string>',
'originalFieldName' => '<string>'
]
],
'forbiddenFeatures' => [
'<string>'
],
'auxiliary' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Basic <encoded-value>",
"Content-Type: application/vnd.composer.v3+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 := "http://10.2.4.166:8080/composer/api/sources/data-entities/describe"
payload := strings.NewReader("{\n \"id\": \"data_entity_id\",\n \"name\": \"Data Entity name\",\n \"nativeFields\": [\n {\n \"origin\": {\n \"derivedOrigin\": {\n \"expression\": \"sales * 100\",\n \"calendarId\": \"<string>\",\n \"referencedFieldNames\": [\n \"<string>\"\n ]\n }\n },\n \"name\": \"field_name\",\n \"label\": \"Field Label\",\n \"visible\": true,\n \"format\": {\n \"time\": {\n \"timeZone\": \"UTC\",\n \"options\": {\n \"hour12\": true\n }\n }\n },\n \"statistics\": {\n \"override\": {\n \"min\": 123,\n \"max\": 123,\n \"distinctValues\": [\n \"<unknown>\"\n ]\n },\n \"cacheEnabled\": true,\n \"refreshable\": true,\n \"cardinality\": 123\n },\n \"facetFiltering\": {\n \"enabled\": true,\n \"order\": 2\n },\n \"disabledCapabilities\": [\n \"<string>\"\n ],\n \"fieldMetadata\": {},\n \"rawFormatSupportTimeGroup\": true,\n \"fieldName\": \"<string>\",\n \"originalFieldName\": \"<string>\"\n }\n ],\n \"forbiddenFeatures\": [\n \"<string>\"\n ],\n \"auxiliary\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Basic <encoded-value>")
req.Header.Add("Content-Type", "application/vnd.composer.v3+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("http://10.2.4.166:8080/composer/api/sources/data-entities/describe")
.header("Authorization", "Basic <encoded-value>")
.header("Content-Type", "application/vnd.composer.v3+json")
.body("{\n \"id\": \"data_entity_id\",\n \"name\": \"Data Entity name\",\n \"nativeFields\": [\n {\n \"origin\": {\n \"derivedOrigin\": {\n \"expression\": \"sales * 100\",\n \"calendarId\": \"<string>\",\n \"referencedFieldNames\": [\n \"<string>\"\n ]\n }\n },\n \"name\": \"field_name\",\n \"label\": \"Field Label\",\n \"visible\": true,\n \"format\": {\n \"time\": {\n \"timeZone\": \"UTC\",\n \"options\": {\n \"hour12\": true\n }\n }\n },\n \"statistics\": {\n \"override\": {\n \"min\": 123,\n \"max\": 123,\n \"distinctValues\": [\n \"<unknown>\"\n ]\n },\n \"cacheEnabled\": true,\n \"refreshable\": true,\n \"cardinality\": 123\n },\n \"facetFiltering\": {\n \"enabled\": true,\n \"order\": 2\n },\n \"disabledCapabilities\": [\n \"<string>\"\n ],\n \"fieldMetadata\": {},\n \"rawFormatSupportTimeGroup\": true,\n \"fieldName\": \"<string>\",\n \"originalFieldName\": \"<string>\"\n }\n ],\n \"forbiddenFeatures\": [\n \"<string>\"\n ],\n \"auxiliary\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://10.2.4.166:8080/composer/api/sources/data-entities/describe")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Basic <encoded-value>'
request["Content-Type"] = 'application/vnd.composer.v3+json'
request.body = "{\n \"id\": \"data_entity_id\",\n \"name\": \"Data Entity name\",\n \"nativeFields\": [\n {\n \"origin\": {\n \"derivedOrigin\": {\n \"expression\": \"sales * 100\",\n \"calendarId\": \"<string>\",\n \"referencedFieldNames\": [\n \"<string>\"\n ]\n }\n },\n \"name\": \"field_name\",\n \"label\": \"Field Label\",\n \"visible\": true,\n \"format\": {\n \"time\": {\n \"timeZone\": \"UTC\",\n \"options\": {\n \"hour12\": true\n }\n }\n },\n \"statistics\": {\n \"override\": {\n \"min\": 123,\n \"max\": 123,\n \"distinctValues\": [\n \"<unknown>\"\n ]\n },\n \"cacheEnabled\": true,\n \"refreshable\": true,\n \"cardinality\": 123\n },\n \"facetFiltering\": {\n \"enabled\": true,\n \"order\": 2\n },\n \"disabledCapabilities\": [\n \"<string>\"\n ],\n \"fieldMetadata\": {},\n \"rawFormatSupportTimeGroup\": true,\n \"fieldName\": \"<string>\",\n \"originalFieldName\": \"<string>\"\n }\n ],\n \"forbiddenFeatures\": [\n \"<string>\"\n ],\n \"auxiliary\": true\n}"
response = http.request(request)
puts response.read_body{
"content": [
{
"type": "ATTRIBUTE",
"originalFieldName": "<string>",
"name": "<string>",
"label": "<string>"
}
]
}{
"error": "<string>",
"details": "<string>",
"message": "<string>",
"path": "<string>",
"status": "<string>",
"code": "<string>",
"errorCode": "<string>",
"timestamp": "<string>",
"problems": [
{
"name": "<string>",
"message": "<string>",
"level": "ERROR",
"dependencies": {}
}
]
}{
"timestamp": "2023-11-07T05:31:56Z",
"status": 123,
"error": "<string>",
"message": "<string>",
"path": "<string>"
}{
"error": "<string>",
"details": "<string>",
"message": "<string>",
"path": "<string>",
"status": "<string>",
"code": "<string>",
"errorCode": "<string>",
"timestamp": "<string>",
"problems": [
{
"name": "<string>",
"message": "<string>",
"level": "ERROR",
"dependencies": {}
}
]
}{
"error": "<string>",
"details": "<string>",
"message": "<string>",
"path": "<string>",
"status": "<string>",
"code": "<string>",
"errorCode": "<string>",
"timestamp": "<string>",
"problems": [
{
"name": "<string>",
"message": "<string>",
"level": "ERROR",
"dependencies": {}
}
]
}Authorizations
HTTP Basic authentication using global administrator credentials (username and password).
Body
Each of the data entity types corresponds to it’s own definition block:
- SINGLE_COLLECTION - singleCollection
- CUSTOM_SQL - customSql
- INDEX - index
- UPLOAD - upload
SINGLE_COLLECTION, CUSTOM_SQL, INDEX, UPLOAD Unique identifier of the source. Must be unique within the source
255"data_entity_id"
User visible representation of the source. It must be unique within the source
255"Data Entity name"
Represents regular JDBC table in the database
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Represents Elasticsearch target for the query. It can be single index, multiple indexes or pattern
Show child attributes
Show child attributes
Represents data uploaded using uploads API
Show child attributes
Show child attributes
This field is optional and will be calculated automatically based on the table if missing. NOTE: List of native fields is not available for the listing endpoint
Show child attributes
Show child attributes
This field is optional and will be calculated automatically based on the table if missing.
Defines raw cache settings for data entity
Show child attributes
Show child attributes
Response
The data entity schema was returned successfully
List of fields detected for the data entity
Show child attributes
Show child attributes
Was this page helpful?