Get a data source view
curl --request GET \
--url https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}', 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://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}",
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: Bearer <token>"
],
]);
$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://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"category": "managed",
"createdAt": 123,
"dataSource": {
"id": 12345,
"createdAt": 1625097600,
"name": "Customer Knowledge Base",
"description": "Contains all customer-related information and FAQs",
"dustAPIProjectId": "5e9d8c7b6a",
"connectorId": "1f3e5d7c9b",
"connectorProvider": "webcrawler",
"assistantDefaultSelected": true
},
"editedByUser": {
"fullName": "<string>",
"editedAt": 123
},
"id": 123,
"kind": "default",
"parentsIn": [
"<string>"
],
"sId": "<string>",
"updatedAt": 123,
"spaceId": "<string>"
}DatasourceViews
Get a data source view
GET
/
api
/
v1
/
w
/
{wId}
/
spaces
/
{spaceId}
/
data_source_views
/
{dsvId}
Get a data source view
curl --request GET \
--url https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}', 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://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}",
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: Bearer <token>"
],
]);
$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://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://dust.tt/api/v1/w/{wId}/spaces/{spaceId}/data_source_views/{dsvId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"category": "managed",
"createdAt": 123,
"dataSource": {
"id": 12345,
"createdAt": 1625097600,
"name": "Customer Knowledge Base",
"description": "Contains all customer-related information and FAQs",
"dustAPIProjectId": "5e9d8c7b6a",
"connectorId": "1f3e5d7c9b",
"connectorProvider": "webcrawler",
"assistantDefaultSelected": true
},
"editedByUser": {
"fullName": "<string>",
"editedAt": 123
},
"id": 123,
"kind": "default",
"parentsIn": [
"<string>"
],
"sId": "<string>",
"updatedAt": 123,
"spaceId": "<string>"
}Authorizations
Your DUST API key is a Bearer token.
Response
Successful response
The category of the data source view
Available options:
managed, folder, website, apps Timestamp of when the data source view was created
Show child attributes
Show child attributes
The user who last edited the data source view
Show child attributes
Show child attributes
Unique identifier for the data source view
The kind of the data source view
Available options:
default, custom List of IDs included in this view, null if complete data source is taken
Unique string identifier for the data source view
Timestamp of when the data source view was last updated
ID of the space containing the data source view