redpanda-data/connect/bloblang-authoring
Claude Code and agent skill by redpanda-data/connect
- community
Checking that the SKILL.md file is still in the repository.
This skill should be used when users need to create or debug Bloblang transformation scripts. Trigger when users ask about transforming data, mapping fields, parsing JSON/CSV/XML, converting timestamps, filtering arrays, or mention "bloblang", "blobl", "mapping processor", or describe any data transformation need like "convert this to that" or "transform my JSON".
Install
npx vskill@latest install redpanda-data/connect/bloblang-authoringSKILL.md
The same SKILL.md was published earlier as redpanda-data/connect/bloblang-authoring.
Redpanda Connect Bloblang Script Generator
Create working, tested Bloblang transformation scripts from natural language descriptions.
Objective
Generate a Bloblang (blobl) script that correctly transforms the user's input data according to their requirements. The script MUST be tested before presenting it.
Setup
This skill requires rpk rpk connect, python3, and jq. See the SETUP for installation instructions.
Tools
Script format-bloblang.sh
Generates category-organized Bloblang reference files in XML format. Run once at the start of each session before searching for functions/methods.
- No arguments
- Generates category files organized by type (e.g.,
functions-General.xml,methods-String_Manipulation.xml) - Outputs generated files to a versioned directory
- Outputs the directory path to stdout (capture in
BLOBLREF_DIRvariable for later use) - Each XML file contains structured function/method definitions with parameters, descriptions, and examples
Functions
Generated function files have functions-<Category>.xml names and contain functions relevant to that category.
functions-Encoding.xml- Schema registry headersfunctions-Environment.xml- Environment vars, files, timestamps, hostnamefunctions-Fake_Data_Generation.xml- Fake data generationfunctions-General.xml- Bytes, counter, deleted, ksuid, nanoid, uuid, random, range, snowflakefunctions-Message_Info.xml- Batch index, content, error, metadata, span links, tracing IDs- etc.
The `function` XML tag format:
nameattribute - function nameparamsattribute - comma-separated list of parameters with types, format<name>:<type>or empty string if no parameters- body - description of function purpose and usage
exampleXML subtagsummaryattribute (optional) - brief description of the example- body - code block demonstrating usage
Example function definition:
Methods
Generated method files have methods-<Category>.xml names and contain methods relevant to that category.
methods-Encoding_and_Encryption.xml- Base64, compression, hashing, encryptionmethods-General.xml- Basic operations, type checkingmethods-GeoIP.xml- GeoIP lookupsmethods-JSON_Web_Tokens.xml- JWT operationsmethods-Number_Manipulation.xml- Arithmetic, rounding, formattingmethods-Object___Array_Manipulation.xml- Filtering, mapping, sorting, mergingmethods-Parsing.xml- JSON, CSV, XML, protocol buffer parsingmethods-Regular_Expressions.xml- Regex matching and replacementmethods-SQL.xml- SQL operationsmethods-String_Manipulation.xml- Case, trimming, splitting, formattingmethods-Timestamp_Manipulation.xml- Parsing, formatting, timezone conversionmethods-Type_Coercion.xml- Type conversions- etc.
The `method` XML tag format:
nameattribute - function nameparamsattribute - comma-separated list of parameters with types, format<name>:<type>or empty string if no parameters- body - description of function purpose and usage
exampleXML subtagsummaryattribute (optional) - brief description of the example- body - code block demonstrating usage
Example method definition:
Grep Search
Lists Available functions and methods without loading full files.
- Requires
BLOBLREF_DIRset to the directory output byformat-bloblang.sh
Script test-blobl.sh
Tests a Bloblang script against input data. Executes the transformation and returns results or errors. Can be run repeatedly during iteration.
- Requires
data.json(input) andscript.blobl(transformation) in the target directory - Returns transformed data or error messages
Bloblang
Bloblang (blobl) is Redpanda Connect's native mapping language for transforming message data. It's designed for readability and safely reshaping documents of any structure.
Core Concepts
Assignment: Create new documents by assigning values to paths.
root= the new document being createdthis= the input document being read
Field Paths: Use dot notation for nested fields. Use quotes for special characters:
Literals: Numbers, booleans, strings, null, arrays, and objects:
Functions and Methods
Functions generate values (no target needed):
Methods transform values (called on a target with .):
Methods can be chained:
Methods require a target (called with .), while functions do not. Check the XML reference files to determine correct usage:
Discovering Available Functions & Methods
Bloblang provides hundreds of functions and methods organized into categories. Start with these foundational categories that cover common use cases:
functions-General.xml- Core utility functions (uuid_v4, timestamp, random, etc.)functions-Message_Info.xml- Message metadata access (hostname, env, content_type, etc.)methods-General.xml- Universal transformations (type conversions, existence checks, etc.)
For specialized needs, consult domain-specific categories: strings (uppercase, trim, regexp), timestamps (ts_parse, ts_format), arrays (map_each, filter), objects (keys, values), encoding (base64, json), and more.
Discovery tools:
- Run
format-bloblang.shto generate category-organized XML reference files in a versioned directory - Use grep patterns to search function/method names, descriptions, parameters, and examples across categories
- Read specific category XML files for structured definitions with complete function signatures, parameter details, and usage examples
Control Flow
Conditionals (if/else):
Pattern Matching (match):
Coalescing (try multiple paths with |):
Note: Use | for alternative field paths (missing fields), use .catch() for operation failures (parse errors, type mismatches).
Common Operations
Deletion:
Variables (reuse values without adding to output):
IMPORTANT: Variables must be declared at the top level, not inside if, match, or other blocks.
Named mappings: (reusable scripts)
Error Handling (provide fallback values):
IMPORTANT: When using .catch() with fallback expressions that reference this.field, store the field in a variable first. Context references in catch chains can be unreliable:
Metadata:
Common Edge Case Patterns
Safe field access with fallbacks
This is the start of the file. Read the full SKILL.md on GitHub.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryChecking.claude-plugin/plugins/redpanda-connect/skills/bloblang-authoring/SKILL.md
Popularity
- Repository stars
- 8,675
- Repository forks
- 943
- 7-day trend score
- 45
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/redpanda-data/connect/bloblang-authoring)