from retab import Retab
client = Retab()
block = client.workflows.blocks.get(
"extract-1",
)
print(block.type, block.label)
print(block.config)
import { Retab } from "@retab/node";
const client = new Retab({ apiKey: process.env.RETAB_API_KEY });
const block = await client.workflows.blocks.get("extract-1");
console.log(block.type, block.label);
console.log(block.config);
package main
import (
"context"
"fmt"
"log"
retab "github.com/retab-dev/retab/clients/go"
)
func ptr[T any](v T) *T { return &v }
func main() {
ctx := context.Background()
client, err := retab.NewClient("")
if err != nil {
log.Fatal(err)
}
block, err := client.Workflows.Blocks.Get(ctx, "extract-1", nil)
if err != nil {
log.Fatal(err)
}
fmt.Println(block.Type, block.Label)
fmt.Println(block.Config)
}
require 'retab'
client = Retab::Client.new(api_key: ENV['RETAB_API_KEY'])
block = client.workflows.blocks.get(block_id: 'extract-1')
puts "#{block.type} #{block.label}"
puts block.config
use retab::resources::workflow_blocks::GetParams;
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 block = client
.workflows().blocks()
.get("extract-1", GetParams::default())
.await?;
println!("{} {}", block.type_, block.label.as_deref().unwrap_or(""));
println!("{:?}", block.config);
Ok(())
}
<?php
require 'vendor/autoload.php';
use Retab\Client;
$client = new Client(apiKey: getenv('RETAB_API_KEY'));
$result = $client->workflows()->blocks()->get(
blockId: 'blk_extract_1',
);
print_r($result);
using Retab;
using RetabClient = Retab.Retab;
var apiKey = Environment.GetEnvironmentVariable("RETAB_API_KEY")!;
var client = new RetabClient(apiKey);
var result = await client.Workflows.Blocks.GetAsync("blk_extract_1", new WorkflowBlocksGetOptions());
Console.WriteLine(result);
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 result = client.workflows().blocks().get("block_abc123", "wf_abc123");
System.out.println(result);
}
}
curl -X 'GET' \
'https://api.retab.com/v1/workflows/blocks/extract-1' \
-H 'Authorization: Bearer <your-api-key>'
{
"id": "extract-1",
"workflow_id": "wf_abc123xyz",
"type": "extract",
"label": "Extract Invoice Fields",
"position_x": 320,
"position_y": 0,
"width": 240,
"height": 120,
"config": {
"model": "gpt-5",
"json_schema": {
"type": "object",
"properties": {
"invoice_number": { "type": "string" },
"total": { "type": "number" }
}
}
},
"parent_id": null,
"updated_at": "2026-05-01T14:30:00Z"
}
{
"detail": "Block not found"
}
Get Block
Get a single block by ID.
from retab import Retab
client = Retab()
block = client.workflows.blocks.get(
"extract-1",
)
print(block.type, block.label)
print(block.config)
import { Retab } from "@retab/node";
const client = new Retab({ apiKey: process.env.RETAB_API_KEY });
const block = await client.workflows.blocks.get("extract-1");
console.log(block.type, block.label);
console.log(block.config);
package main
import (
"context"
"fmt"
"log"
retab "github.com/retab-dev/retab/clients/go"
)
func ptr[T any](v T) *T { return &v }
func main() {
ctx := context.Background()
client, err := retab.NewClient("")
if err != nil {
log.Fatal(err)
}
block, err := client.Workflows.Blocks.Get(ctx, "extract-1", nil)
if err != nil {
log.Fatal(err)
}
fmt.Println(block.Type, block.Label)
fmt.Println(block.Config)
}
require 'retab'
client = Retab::Client.new(api_key: ENV['RETAB_API_KEY'])
block = client.workflows.blocks.get(block_id: 'extract-1')
puts "#{block.type} #{block.label}"
puts block.config
use retab::resources::workflow_blocks::GetParams;
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 block = client
.workflows().blocks()
.get("extract-1", GetParams::default())
.await?;
println!("{} {}", block.type_, block.label.as_deref().unwrap_or(""));
println!("{:?}", block.config);
Ok(())
}
<?php
require 'vendor/autoload.php';
use Retab\Client;
$client = new Client(apiKey: getenv('RETAB_API_KEY'));
$result = $client->workflows()->blocks()->get(
blockId: 'blk_extract_1',
);
print_r($result);
using Retab;
using RetabClient = Retab.Retab;
var apiKey = Environment.GetEnvironmentVariable("RETAB_API_KEY")!;
var client = new RetabClient(apiKey);
var result = await client.Workflows.Blocks.GetAsync("blk_extract_1", new WorkflowBlocksGetOptions());
Console.WriteLine(result);
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 result = client.workflows().blocks().get("block_abc123", "wf_abc123");
System.out.println(result);
}
}
curl -X 'GET' \
'https://api.retab.com/v1/workflows/blocks/extract-1' \
-H 'Authorization: Bearer <your-api-key>'
{
"id": "extract-1",
"workflow_id": "wf_abc123xyz",
"type": "extract",
"label": "Extract Invoice Fields",
"position_x": 320,
"position_y": 0,
"width": 240,
"height": 120,
"config": {
"model": "gpt-5",
"json_schema": {
"type": "object",
"properties": {
"invoice_number": { "type": "string" },
"total": { "type": "number" }
}
}
},
"parent_id": null,
"updated_at": "2026-05-01T14:30:00Z"
}
{
"detail": "Block not found"
}
from retab import Retab
client = Retab()
block = client.workflows.blocks.get(
"extract-1",
)
print(block.type, block.label)
print(block.config)
import { Retab } from "@retab/node";
const client = new Retab({ apiKey: process.env.RETAB_API_KEY });
const block = await client.workflows.blocks.get("extract-1");
console.log(block.type, block.label);
console.log(block.config);
package main
import (
"context"
"fmt"
"log"
retab "github.com/retab-dev/retab/clients/go"
)
func ptr[T any](v T) *T { return &v }
func main() {
ctx := context.Background()
client, err := retab.NewClient("")
if err != nil {
log.Fatal(err)
}
block, err := client.Workflows.Blocks.Get(ctx, "extract-1", nil)
if err != nil {
log.Fatal(err)
}
fmt.Println(block.Type, block.Label)
fmt.Println(block.Config)
}
require 'retab'
client = Retab::Client.new(api_key: ENV['RETAB_API_KEY'])
block = client.workflows.blocks.get(block_id: 'extract-1')
puts "#{block.type} #{block.label}"
puts block.config
use retab::resources::workflow_blocks::GetParams;
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 block = client
.workflows().blocks()
.get("extract-1", GetParams::default())
.await?;
println!("{} {}", block.type_, block.label.as_deref().unwrap_or(""));
println!("{:?}", block.config);
Ok(())
}
<?php
require 'vendor/autoload.php';
use Retab\Client;
$client = new Client(apiKey: getenv('RETAB_API_KEY'));
$result = $client->workflows()->blocks()->get(
blockId: 'blk_extract_1',
);
print_r($result);
using Retab;
using RetabClient = Retab.Retab;
var apiKey = Environment.GetEnvironmentVariable("RETAB_API_KEY")!;
var client = new RetabClient(apiKey);
var result = await client.Workflows.Blocks.GetAsync("blk_extract_1", new WorkflowBlocksGetOptions());
Console.WriteLine(result);
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 result = client.workflows().blocks().get("block_abc123", "wf_abc123");
System.out.println(result);
}
}
curl -X 'GET' \
'https://api.retab.com/v1/workflows/blocks/extract-1' \
-H 'Authorization: Bearer <your-api-key>'
{
"id": "extract-1",
"workflow_id": "wf_abc123xyz",
"type": "extract",
"label": "Extract Invoice Fields",
"position_x": 320,
"position_y": 0,
"width": 240,
"height": 120,
"config": {
"model": "gpt-5",
"json_schema": {
"type": "object",
"properties": {
"invoice_number": { "type": "string" },
"total": { "type": "number" }
}
}
},
"parent_id": null,
"updated_at": "2026-05-01T14:30:00Z"
}
{
"detail": "Block not found"
}
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Path Parameters
Query Parameters
Disambiguates a block id that is shared by more than one workflow. Required only when the block id is not unique within your organization — otherwise the call returns 409 listing the colliding workflow_ids. Server-generated block IDs are always unique and never need this.
Response
Successful Response
Public live workflow block object.
Foreign key to workflow
Block type (extract, parse, classifier, etc.)
start_document, start_json, note, parse, edit, extract, split, classifier, conditional, api_call, function, while_loop, for_each, merge_dicts, while_loop_sentinel_start, while_loop_sentinel_end, for_each_sentinel_start, for_each_sentinel_end Display label for the block
X position on canvas
Y position on canvas
Block width for resizable blocks
Block height for resizable blocks
Block-specific configuration
ID of parent container (while_loop, for_each)
Canonical declarative block path used to reconcile imported specs.
Authored declarative block id before import-time id regeneration.
Schemas resolved for this block from the workflow graph.