Skip to main content
GET
/
api
/
v1
/
data_sources
List data sources
curl --request GET \
  --url https://app.datafold.com/api/v1/data_sources \
  --header 'Authorization: <api-key>'
import requests

url = "https://app.datafold.com/api/v1/data_sources"

headers = {"Authorization": "<api-key>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: '<api-key>'}};

fetch('https://app.datafold.com/api/v1/data_sources', 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://app.datafold.com/api/v1/data_sources",
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: <api-key>"
],
]);

$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://app.datafold.com/api/v1/data_sources"

req, _ := http.NewRequest("GET", url, nil)

req.Header.Add("Authorization", "<api-key>")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.get("https://app.datafold.com/api/v1/data_sources")
.header("Authorization", "<api-key>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://app.datafold.com/api/v1/data_sources")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'

response = http.request(request)
puts response.read_body
[
  {
    "name": "<string>",
    "type": "<string>",
    "accessible": true,
    "catalog_exclude_list": "<string>",
    "catalog_include_list": "<string>",
    "created_from": "<string>",
    "data_retention_days": 123,
    "disable_profiling": false,
    "disable_schema_indexing": false,
    "float_tolerance": 0,
    "group_ids": [
      123
    ],
    "groups": {},
    "hidden": false,
    "id": 123,
    "is_paused": false,
    "last_test": {
      "results": [
        {
          "result": null
        }
      ],
      "tested_at": "2023-11-07T05:31:56Z"
    },
    "lineage_schedule": "<string>",
    "max_allowed_connections": 123,
    "oauth_dwh_active": true,
    "options": {
      "projectId": "<string>",
      "extraProjectsToIndex": "project1\nproject2",
      "jsonOAuthKeyFile": "<string>",
      "location": "US",
      "totalMBytesProcessedLimit": 123,
      "useStandardSql": true,
      "userDefinedFunctionResourceUri": "gs://bucket/date_utils.js"
    },
    "profile_exclude_list": "<string>",
    "profile_include_list": "<string>",
    "profile_schedule": "<string>",
    "queue_name": "<string>",
    "scheduled_queue_name": "<string>",
    "schema_indexing_schedule": "<string>",
    "schema_max_age_s": 123,
    "secret_id": 123,
    "source": "<string>",
    "temp_schema": "<string>",
    "view_only": false
  }
]

Authorizations

Authorization
string
header
required

Use the 'Authorization' header with the format 'Key '

Response

200 - application/json

Successful Response

name
string
required
type
string
required
Allowed value: "bigquery"
accessible
boolean
default:true
catalog_exclude_list
string | null
catalog_include_list
string | null
created_from
string | null
data_retention_days
integer | null
disable_profiling
boolean | null
default:false
disable_schema_indexing
boolean | null
default:false
float_tolerance
number | null
default:0
group_ids
integer[] | null
groups
Groups · object | null
hidden
boolean | null
default:false
id
integer | null
is_paused
boolean | null
default:false
last_test
ApiDataSourceTestStatus · object | null
lineage_schedule
string | null
max_allowed_connections
integer | null
oauth_dwh_active
boolean | null
options
BigQueryConfig · object | null
profile_exclude_list
string | null
profile_include_list
string | null
profile_schedule
string | null
queue_name
string | null
scheduled_queue_name
string | null
schema_indexing_schedule
string | null
schema_max_age_s
integer | null
secret_id
integer | null
source
string | null
temp_schema
string | null
view_only
boolean | null
default:false