Python
import os
from meibel import MeibelClient
client = MeibelClient(api_key=os.environ["MEIBEL_API_KEY"])
status = client.datasources.ingest.get_status(datasource_id="ds_8f3a2b1c")
print(f"Status: {status.status}, started at: {status.started_at}")
for method in status.methods:
print(f"{method.method}: {method.processed_files}/{method.total_files} processed, {method.errors} errors")import { MeibelClient } from "meibel";
const client = new MeibelClient({ apiKey: process.env.MEIBEL_API_KEY });
const status = await client.datasources.ingest.getStatus("ds_8f3a1c2b9d4e");
console.log(`Status: ${status.status}, started at: ${status.started_at}`);
for (const method of status.methods) {
console.log(
`${method.method}: ${method.processed_files}/${method.total_files} processed, ${method.errors} errors`
);
}package main
import (
"context"
"fmt"
"os"
v2 "github.com/meibel-ai/meibel-go/v2"
)
func main() {
client := v2.NewClient(v2.WithAPIKey(os.Getenv("MEIBEL_API_KEY")))
status, err := client.Datasources.Ingest.GetStatus(context.Background(), "ds_8f3a2b1c")
if err != nil {
panic(err)
}
fmt.Printf("Status: %s\n", status.Status)
for _, m := range status.Methods {
fmt.Printf("Method %s: %d/%d files processed\n", m.Method, m.ProcessedFiles, m.TotalFiles)
}
}curl --request GET \
--url https://api.meibel.ai/v2/datasources/{datasource_id}/ingest-status \
--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}/ingest-status', 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}/ingest-status",
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}/ingest-status")
.header("Meibel-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.meibel.ai/v2/datasources/{datasource_id}/ingest-status")
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{
"datasource_id": "<string>",
"started_at": "<string>",
"completed_at": "<string>",
"methods": []
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Ingest
Get Ingest Status
GET
/
datasources
/
{datasource_id}
/
ingest-status
Python
import os
from meibel import MeibelClient
client = MeibelClient(api_key=os.environ["MEIBEL_API_KEY"])
status = client.datasources.ingest.get_status(datasource_id="ds_8f3a2b1c")
print(f"Status: {status.status}, started at: {status.started_at}")
for method in status.methods:
print(f"{method.method}: {method.processed_files}/{method.total_files} processed, {method.errors} errors")import { MeibelClient } from "meibel";
const client = new MeibelClient({ apiKey: process.env.MEIBEL_API_KEY });
const status = await client.datasources.ingest.getStatus("ds_8f3a1c2b9d4e");
console.log(`Status: ${status.status}, started at: ${status.started_at}`);
for (const method of status.methods) {
console.log(
`${method.method}: ${method.processed_files}/${method.total_files} processed, ${method.errors} errors`
);
}package main
import (
"context"
"fmt"
"os"
v2 "github.com/meibel-ai/meibel-go/v2"
)
func main() {
client := v2.NewClient(v2.WithAPIKey(os.Getenv("MEIBEL_API_KEY")))
status, err := client.Datasources.Ingest.GetStatus(context.Background(), "ds_8f3a2b1c")
if err != nil {
panic(err)
}
fmt.Printf("Status: %s\n", status.Status)
for _, m := range status.Methods {
fmt.Printf("Method %s: %d/%d files processed\n", m.Method, m.ProcessedFiles, m.TotalFiles)
}
}curl --request GET \
--url https://api.meibel.ai/v2/datasources/{datasource_id}/ingest-status \
--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}/ingest-status', 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}/ingest-status",
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}/ingest-status")
.header("Meibel-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.meibel.ai/v2/datasources/{datasource_id}/ingest-status")
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{
"datasource_id": "<string>",
"started_at": "<string>",
"completed_at": "<string>",
"methods": []
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Authorizations
Path Parameters
Response
Successful Response
Status of the most recent ingest run for a datasource.
ID of the datasource
Overall run status
Available options:
not_started, running, completed, failed, canceled, terminated, timed_out, unknown ISO 8601 timestamp when this run started
ISO 8601 timestamp when this run finished — null while still running
Per-method progress and counts for this run
Show child attributes
Show child attributes
Was this page helpful?
⌘I