curl --request DELETE \
--url https://api.example.com/api/core/knowledge_sources/{knowledge_source_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.example.com/api/core/knowledge_sources/{knowledge_source_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.example.com/api/core/knowledge_sources/{knowledge_source_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_URL => "https://api.example.com/api/core/knowledge_sources/{knowledge_source_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
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://api.example.com/api/core/knowledge_sources/{knowledge_source_id}"
req, _ := http.NewRequest("DELETE", 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.delete("https://api.example.com/api/core/knowledge_sources/{knowledge_source_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/core/knowledge_sources/{knowledge_source_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"file_source_type": "agent-builder",
"deleted": false,
"permissions_type": "managed",
"retrieval_k": 100
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Delete knowledge source
Delete a knowledge source including all associated resources such as sync settings, datastores, and bucket files.
curl --request DELETE \
--url https://api.example.com/api/core/knowledge_sources/{knowledge_source_id} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.example.com/api/core/knowledge_sources/{knowledge_source_id}"
headers = {"Authorization": "Bearer <token>"}
response = requests.delete(url, headers=headers)
print(response.text)const options = {method: 'DELETE', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.example.com/api/core/knowledge_sources/{knowledge_source_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_URL => "https://api.example.com/api/core/knowledge_sources/{knowledge_source_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
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://api.example.com/api/core/knowledge_sources/{knowledge_source_id}"
req, _ := http.NewRequest("DELETE", 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.delete("https://api.example.com/api/core/knowledge_sources/{knowledge_source_id}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/api/core/knowledge_sources/{knowledge_source_id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "<string>",
"file_source_type": "agent-builder",
"deleted": false,
"permissions_type": "managed",
"retrieval_k": 100
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
Bearer token authentication. Format: 'Bearer '
Path Parameters
Query Parameters
Response
Successful Response
Represents managed knowledge sources. These are managed by a system admin or Genow. Each managed knowledge source has a corresponding permission that looks like this: useCase.<use_case_id>.knowledgeAsset.<knowledge_asset_id>.knowledgeSource.<source_id>.read Permissions on knowledge sources are granted in the context of the use case and knowledge asset that the source is assigned to.
Example: Let's say there is a managed knowledge Asset with the id 'asset-1' that contains two managed knowledge sources with the ids 'source-1' and 'source-2'. asset-1 ├── source-1 └── source-2 If a user has the permission 'useCase.use-case-1.knowledgeAsset.asset-1.knowledgeSource.source-1.read', they can see 'asset-1' in the frontend, and if they search on that asset, they will only be able to access sources from source-1 and documents from source-2 will not be included in the search. Wildcards can be used in permissions to grant access to all knowledge sources in a use case or knowledge asset. For example, if a user has the permission 'useCase.use-case-1.knowledgeAsset.asset-1.knowledgeSource.*.read', they can see 'asset-1' in the frontend, and if they search on that asset, they will be able to access all sources from 'asset-1'.
Represents the type of file sources that are within the knowledge source.
agent-builder, cloud-bucket, external-web-search, disa-agent, one-losp-agent-lmh, one-losp-agent-still, one-losp-agent-still-specialized-teams, sap-btp-agent, direct-url Enumeration for the different permissions types associated with knowledge sources
personal, managed x <= 100Was this page helpful?

