from retab import Retab
client = Retab()
split = client.splits.create_split_cancel("splt_01G34H8J2K")
print(split.status)
import { Retab } from "@retab/node";
const client = new Retab({ apiKey: process.env.RETAB_API_KEY });
const split = await client.splits.create_split_cancel("splt_01G34H8J2K");
console.log(split.status);
package main
import (
"context"
"fmt"
"log"
retab "github.com/retab-dev/retab/clients/go"
)
func main() {
client, err := retab.NewClient("")
if err != nil {
log.Fatal(err)
}
split, err := client.Splits.CreateCancel(context.Background(), "splt_01G34H8J2K")
if err != nil {
log.Fatal(err)
}
fmt.Println(split.Status)
}
import com.retab.RetabClient;
public final class Example {
public static void main(String[] args) throws Exception {
RetabClient client = new RetabClient(System.getenv("RETAB_API_KEY"));
var split = client.splits().createCancel("splt_01G34H8J2K");
System.out.println(split.getStatus());
}
}
require 'retab'
client = Retab::Client.new(api_key: ENV['RETAB_API_KEY'])
split = client.splits.create_split_cancel(split_id: 'splt_01G34H8J2K')
puts split.status
use retab::Retab;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let client = Retab::new(std::env::var("RETAB_API_KEY")?);
let split = client.splits().create_split_cancel("splt_01G34H8J2K").await?;
println!("{:?}", split.status);
Ok(())
}
<?php
require 'vendor/autoload.php';
use Retab\Client;
$client = new Client(apiKey: getenv('RETAB_API_KEY'));
$split = $client->splits()->createSplitCancel('splt_01G34H8J2K');
echo $split->status?->value . PHP_EOL;
using Retab;
using RetabClient = Retab.Retab;
var apiKey = Environment.GetEnvironmentVariable("RETAB_API_KEY")!;
var client = new RetabClient(apiKey);
var split = await client.Splits.CreateCancelAsync("splt_01G34H8J2K");
Console.WriteLine(split.Status);
curl -X POST \
'https://api.retab.com/v1/splits/splt_01G34H8J2K/cancel' \
-H "Authorization: Bearer $RETAB_API_KEY"
{
"id": "splt_01G34H8J2K",
"status": "cancelled",
"error": null
}
{
"detail": "split 'splt_01G34H8J2K' not found"
}
Cancel Split
from retab import Retab
client = Retab()
split = client.splits.create_split_cancel("splt_01G34H8J2K")
print(split.status)
import { Retab } from "@retab/node";
const client = new Retab({ apiKey: process.env.RETAB_API_KEY });
const split = await client.splits.create_split_cancel("splt_01G34H8J2K");
console.log(split.status);
package main
import (
"context"
"fmt"
"log"
retab "github.com/retab-dev/retab/clients/go"
)
func main() {
client, err := retab.NewClient("")
if err != nil {
log.Fatal(err)
}
split, err := client.Splits.CreateCancel(context.Background(), "splt_01G34H8J2K")
if err != nil {
log.Fatal(err)
}
fmt.Println(split.Status)
}
import com.retab.RetabClient;
public final class Example {
public static void main(String[] args) throws Exception {
RetabClient client = new RetabClient(System.getenv("RETAB_API_KEY"));
var split = client.splits().createCancel("splt_01G34H8J2K");
System.out.println(split.getStatus());
}
}
require 'retab'
client = Retab::Client.new(api_key: ENV['RETAB_API_KEY'])
split = client.splits.create_split_cancel(split_id: 'splt_01G34H8J2K')
puts split.status
use retab::Retab;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let client = Retab::new(std::env::var("RETAB_API_KEY")?);
let split = client.splits().create_split_cancel("splt_01G34H8J2K").await?;
println!("{:?}", split.status);
Ok(())
}
<?php
require 'vendor/autoload.php';
use Retab\Client;
$client = new Client(apiKey: getenv('RETAB_API_KEY'));
$split = $client->splits()->createSplitCancel('splt_01G34H8J2K');
echo $split->status?->value . PHP_EOL;
using Retab;
using RetabClient = Retab.Retab;
var apiKey = Environment.GetEnvironmentVariable("RETAB_API_KEY")!;
var client = new RetabClient(apiKey);
var split = await client.Splits.CreateCancelAsync("splt_01G34H8J2K");
Console.WriteLine(split.Status);
curl -X POST \
'https://api.retab.com/v1/splits/splt_01G34H8J2K/cancel' \
-H "Authorization: Bearer $RETAB_API_KEY"
{
"id": "splt_01G34H8J2K",
"status": "cancelled",
"error": null
}
{
"detail": "split 'splt_01G34H8J2K' not found"
}
Split run (one created with background: true). Cancellation is idempotent: a run that has already reached a terminal state (completed, failed, or cancelled) is returned unchanged rather than erroring.
from retab import Retab
client = Retab()
split = client.splits.create_split_cancel("splt_01G34H8J2K")
print(split.status)
import { Retab } from "@retab/node";
const client = new Retab({ apiKey: process.env.RETAB_API_KEY });
const split = await client.splits.create_split_cancel("splt_01G34H8J2K");
console.log(split.status);
package main
import (
"context"
"fmt"
"log"
retab "github.com/retab-dev/retab/clients/go"
)
func main() {
client, err := retab.NewClient("")
if err != nil {
log.Fatal(err)
}
split, err := client.Splits.CreateCancel(context.Background(), "splt_01G34H8J2K")
if err != nil {
log.Fatal(err)
}
fmt.Println(split.Status)
}
import com.retab.RetabClient;
public final class Example {
public static void main(String[] args) throws Exception {
RetabClient client = new RetabClient(System.getenv("RETAB_API_KEY"));
var split = client.splits().createCancel("splt_01G34H8J2K");
System.out.println(split.getStatus());
}
}
require 'retab'
client = Retab::Client.new(api_key: ENV['RETAB_API_KEY'])
split = client.splits.create_split_cancel(split_id: 'splt_01G34H8J2K')
puts split.status
use retab::Retab;
#[tokio::main]
async fn main() -> Result<(), Box<dyn std::error::Error>> {
let client = Retab::new(std::env::var("RETAB_API_KEY")?);
let split = client.splits().create_split_cancel("splt_01G34H8J2K").await?;
println!("{:?}", split.status);
Ok(())
}
<?php
require 'vendor/autoload.php';
use Retab\Client;
$client = new Client(apiKey: getenv('RETAB_API_KEY'));
$split = $client->splits()->createSplitCancel('splt_01G34H8J2K');
echo $split->status?->value . PHP_EOL;
using Retab;
using RetabClient = Retab.Retab;
var apiKey = Environment.GetEnvironmentVariable("RETAB_API_KEY")!;
var client = new RetabClient(apiKey);
var split = await client.Splits.CreateCancelAsync("splt_01G34H8J2K");
Console.WriteLine(split.Status);
curl -X POST \
'https://api.retab.com/v1/splits/splt_01G34H8J2K/cancel' \
-H "Authorization: Bearer $RETAB_API_KEY"
{
"id": "splt_01G34H8J2K",
"status": "cancelled",
"error": null
}
{
"detail": "split 'splt_01G34H8J2K' not found"
}
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Response
Successful Response
A split result: a document divided into its constituent subdocuments.
Unique identifier of the split result
Information about the split file
Show child attributes
Show child attributes
Model used for the split operation
Subdocuments used for the split operation
Show child attributes
Show child attributes
Number of consensus votes used
Free-form instructions supplied with the split request.
The list of document splits with their assigned pages. Empty [] until status == 'completed'.
Show child attributes
Show child attributes
Lifecycle status. The synchronous path returns 'completed'. Background runs progress pending -> queued -> in_progress -> completed | failed | cancelled.
pending, queued, in_progress, completed, failed, cancelled Error details when a background run fails; null otherwise. Always present so consumers can read it without an existence check.
Show child attributes
Show child attributes
Consensus metadata for multi-vote split runs
Show child attributes
Show child attributes
Usage information for the split operation
Show child attributes
Show child attributes