Expand table selection via FK relationships
curl --request POST \
--url https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Project-ID: <x-project-id>' \
--data '
{
"table_fqns": [
"<string>"
],
"max_hops": 2,
"include_input_tables": true
}
'import requests
url = "https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand"
payload = {
"table_fqns": ["<string>"],
"max_hops": 2,
"include_input_tables": True
}
headers = {
"X-Project-ID": "<x-project-id>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Project-ID': '<x-project-id>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({table_fqns: ['<string>'], max_hops: 2, include_input_tables: true})
};
fetch('https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand', 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/utils/{resource_type}/{resource_uri}/fk-edges/expand",
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([
'table_fqns' => [
'<string>'
],
'max_hops' => 2,
'include_input_tables' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"X-Project-ID: <x-project-id>"
],
]);
$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 := "https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand"
payload := strings.NewReader("{\n \"table_fqns\": [\n \"<string>\"\n ],\n \"max_hops\": 2,\n \"include_input_tables\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Project-ID", "<x-project-id>")
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand")
.header("X-Project-ID", "<x-project-id>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"table_fqns\": [\n \"<string>\"\n ],\n \"max_hops\": 2,\n \"include_input_tables\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Project-ID"] = '<x-project-id>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"table_fqns\": [\n \"<string>\"\n ],\n \"max_hops\": 2,\n \"include_input_tables\": true\n}"
response = http.request(request)
puts response.read_body{
"tables": [
"<string>"
],
"junction_tables": [
"<string>"
],
"edges_examined": 123
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}fk-graph
Expand table selection via FK relationships
Given a list of table FQNs, discover related tables via FK traversal (BFS).
POST
/
utils
/
{resource_type}
/
{resource_uri}
/
fk-edges
/
expand
Expand table selection via FK relationships
curl --request POST \
--url https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--header 'X-Project-ID: <x-project-id>' \
--data '
{
"table_fqns": [
"<string>"
],
"max_hops": 2,
"include_input_tables": true
}
'import requests
url = "https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand"
payload = {
"table_fqns": ["<string>"],
"max_hops": 2,
"include_input_tables": True
}
headers = {
"X-Project-ID": "<x-project-id>",
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'X-Project-ID': '<x-project-id>',
Authorization: 'Bearer <token>',
'Content-Type': 'application/json'
},
body: JSON.stringify({table_fqns: ['<string>'], max_hops: 2, include_input_tables: true})
};
fetch('https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand', 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/utils/{resource_type}/{resource_uri}/fk-edges/expand",
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([
'table_fqns' => [
'<string>'
],
'max_hops' => 2,
'include_input_tables' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json",
"X-Project-ID: <x-project-id>"
],
]);
$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 := "https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand"
payload := strings.NewReader("{\n \"table_fqns\": [\n \"<string>\"\n ],\n \"max_hops\": 2,\n \"include_input_tables\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-Project-ID", "<x-project-id>")
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand")
.header("X-Project-ID", "<x-project-id>")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"table_fqns\": [\n \"<string>\"\n ],\n \"max_hops\": 2,\n \"include_input_tables\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.example.com/utils/{resource_type}/{resource_uri}/fk-edges/expand")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-Project-ID"] = '<x-project-id>'
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"table_fqns\": [\n \"<string>\"\n ],\n \"max_hops\": 2,\n \"include_input_tables\": true\n}"
response = http.request(request)
puts response.read_body{
"tables": [
"<string>"
],
"junction_tables": [
"<string>"
],
"edges_examined": 123
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}{
"error": {
"message": "<string>",
"request_id": "<string>",
"timestamp": "2023-11-07T05:31:56Z",
"details": {}
}
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Headers
Body
application/json
Request to expand table selection via FK relationships.
Was this page helpful?
⌘I

