Python
import os
from meibel import MeibelClient
client = MeibelClient(api_key=os.environ["MEIBEL_API_KEY"])
tables = client.datasources.tables.list(datasource_id="ds_abc123")
for table in tables:
print(f"{table.table_name}: {table.description}")import { MeibelClient } from "meibel";
const client = new MeibelClient({ apiKey: process.env.MEIBEL_API_KEY });
const tables = await client.datasources.tables.list("ds_9f8c2a1b4e6d");
for (const table of tables) {
console.log(`${table.table_name}: ${table.description}`);
}package main
import (
"context"
"fmt"
"os"
"github.com/meibel-ai/meibel-go/v2"
)
func main() {
client := v2.NewClient(v2.WithAPIKey(os.Getenv("MEIBEL_API_KEY")))
tables, err := client.Datasources.Tables.List(context.Background(), "ds_8f2a3c1d9e")
if err != nil {
panic(err)
}
for _, table := range tables {
fmt.Printf("%s: %s\n", table.TableName, table.Description)
}
}curl --request GET \
--url https://api.meibel.ai/v2/datasources/{datasource_id}/tables \
--header 'Meibel-API-Key: <api-key>'const options = {method: 'GET', headers: {'Meibel-API-Key': '<api-key>'}};
fetch('https://api.meibel.ai/v2/datasources/{datasource_id}/tables', 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.meibel.ai/v2/datasources/{datasource_id}/tables",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Meibel-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.get("https://api.meibel.ai/v2/datasources/{datasource_id}/tables")
.header("Meibel-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.meibel.ai/v2/datasources/{datasource_id}/tables")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Meibel-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"table_name": "<string>",
"description": "<string>",
"columns": [
{
"column_name": "<string>",
"type": "<string>",
"description": "<string>"
}
]
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Tables
List Tables
GET
/
datasources
/
{datasource_id}
/
tables
Python
import os
from meibel import MeibelClient
client = MeibelClient(api_key=os.environ["MEIBEL_API_KEY"])
tables = client.datasources.tables.list(datasource_id="ds_abc123")
for table in tables:
print(f"{table.table_name}: {table.description}")import { MeibelClient } from "meibel";
const client = new MeibelClient({ apiKey: process.env.MEIBEL_API_KEY });
const tables = await client.datasources.tables.list("ds_9f8c2a1b4e6d");
for (const table of tables) {
console.log(`${table.table_name}: ${table.description}`);
}package main
import (
"context"
"fmt"
"os"
"github.com/meibel-ai/meibel-go/v2"
)
func main() {
client := v2.NewClient(v2.WithAPIKey(os.Getenv("MEIBEL_API_KEY")))
tables, err := client.Datasources.Tables.List(context.Background(), "ds_8f2a3c1d9e")
if err != nil {
panic(err)
}
for _, table := range tables {
fmt.Printf("%s: %s\n", table.TableName, table.Description)
}
}curl --request GET \
--url https://api.meibel.ai/v2/datasources/{datasource_id}/tables \
--header 'Meibel-API-Key: <api-key>'const options = {method: 'GET', headers: {'Meibel-API-Key': '<api-key>'}};
fetch('https://api.meibel.ai/v2/datasources/{datasource_id}/tables', 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.meibel.ai/v2/datasources/{datasource_id}/tables",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Meibel-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}HttpResponse<String> response = Unirest.get("https://api.meibel.ai/v2/datasources/{datasource_id}/tables")
.header("Meibel-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.meibel.ai/v2/datasources/{datasource_id}/tables")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Meibel-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body[
{
"table_name": "<string>",
"description": "<string>",
"columns": [
{
"column_name": "<string>",
"type": "<string>",
"description": "<string>"
}
]
}
]{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
Path Parameters
Query Parameters
Include columns for each table
Response
Successful Response
Was this page helpful?
⌘I