Skip to main content
Version: 96.2
CommunityEnterprise

Extended examples

Interactive examples!

All examples on this page are fully interactive! You can modify both the kJQ filter and the JSON data in real-time to see how different filters work.

Changes update instantly as you type, making it easy to experiment and learn kJQ syntax.

Type conversion transforms​

Converting data types​

Transform and validate data types in Kafka messages:

JSON Input
Filter Result

Parsing nested JSON​

Extract data from JSON strings within Kafka messages:

JSON Input
Filter Result

Date and time operations​

Current time filtering​

Filter recent events using now:

JSON Input
Filter Result

Duration-based filtering​

Find sessions lasting more than 30 minutes:

JSON Input
Filter Result

Numeric operations​

Statistical analysis​

Find maximum transaction amounts:

JSON Input
Filter Result

Financial calculations​

Calculate and validate price ranges:

JSON Input
Filter Result

String operations​

Text processing pipeline​

Clean and validate user input:

JSON Input
Filter Result

String validation chain​

Validate email domains after cleaning:

JSON Input
Filter Result

Array operations​

Data processing pipeline​

Process and analyze arrays in Kafka messages:

JSON Input
Filter Result

Unique values analysis​

Find unique visitor countries:

JSON Input
Filter Result

Array flattening​

Process nested category structures:

JSON Input
Filter Result

Object operations​

Key-value analysis​

Analyze configuration changes:

JSON Input
Filter Result

Value extraction​

Extract and validate configuration values:

JSON Input
Filter Result

Advanced math operations​

Modulo operations​

Partition data based on user ID:

JSON Input
Filter Result

Quotient and remainder​

Analyze batch processing metrics:

JSON Input
Filter Result

Object functions​

Contains key​

Checks for the presence of a key:

JSON Input
Filter Result

Containment checks​

Validate if current value exists in allowed lists:

JSON Input
Filter Result

String inside​

Check if an error code exists within a larger error classification string:

JSON Input
Filter Result

String functions​

Advanced string matching​

Complex domain validation:

JSON Input
Filter Result

Pattern matching​

Validate transaction IDs with regex:

JSON Input
Filter Result

Text analysis​

Check if error messages contain specific terms:

JSON Input
Filter Result

Array to string conversion​

Join tags for search indexing:

JSON Input
Filter Result

Utility operations​

Empty value detection​

Filter out incomplete records:

JSON Input
Filter Result

Tagged literals​

Date literals​

Compare against specific dates:

JSON Input
Filter Result

UUID literals​

Match specific system-generated IDs:

JSON Input
Filter Result

Complex real-world examples​

E-commerce order processing​

Multi-condition validation for order processing:

JSON Input
Filter Result

IoT sensor data analysis​

Log analysis and alerting​

Parse and analyze application logs:

JSON Input
Filter Result