Function Overview¶
jpx provides 400+ functions organized into 31 categories.
Discovering Functions¶
List All Functions¶
List by Category¶
Get Function Details¶
Categories¶
| Category | Description | Count |
|---|---|---|
| Array | Functions for working with arrays: chunking, filtering, tran... | 27 |
| Color | Color manipulation and conversion functions. | 8 |
| Computing | Computing-related utility functions. | 9 |
| Date/Time | Functions for working with dates and times: parsing, formatt... | 26 |
| Duration | Functions for working with time durations. | 8 |
| Encoding | Encoding and decoding functions: Base64, hex, URL encoding, ... | 10 |
| Expression | Higher-order functions that work with JMESPath expressions a... | 33 |
| Format | Data formatting functions for numbers, currencies, and other... | 6 |
| Fuzzy | Fuzzy matching and string similarity functions. | 9 |
| Geolocation | Geolocation functions: distance calculation, coordinate pars... | 10 |
| Hash | Cryptographic hash functions: MD5, SHA family, and other has... | 9 |
| ID Generation | Functions for generating various types of unique identifiers... | 3 |
| JSON Patch | JSON Patch (RFC 6902) functions: applying patches, generatin... | 3 |
| Language | Natural language processing functions. | 5 |
| Math | Mathematical and statistical functions: arithmetic, rounding... | 35 |
| Multi-Match | Functions for matching multiple patterns or expressions in a... | 10 |
| Network | Network-related functions: IP addresses, CIDR notation, and ... | 7 |
| Object | Functions for working with JSON objects: merging, filtering ... | 48 |
| Path | File path manipulation functions. | 7 |
| Phonetic | Phonetic encoding functions for sound-based string matching. | 9 |
| Random | Functions for generating random values: numbers, strings, an... | 5 |
| Regular Expression | Regular expression functions: matching, replacing, splitting... | 5 |
| Semantic Versioning | Semantic versioning functions: parsing, comparing, and manip... | 7 |
| Standard JMESPath | These are the standard JMESPath functions as defined in the ... | 26 |
| String | Functions for string manipulation: case conversion, splittin... | 36 |
| Text | Text analysis and processing functions. | 11 |
| Type | Type conversion and checking functions. | 13 |
| URL | Functions for parsing and manipulating URLs and their compon... | 6 |
| Utility | General utility functions that don't fit other categories. | 11 |
| UUID | Functions for generating and working with UUIDs. | 1 |
| Validation | Functions for validating data: email, URL, UUID, and format ... | 13 |
Function Syntax¶
Functions are called with parentheses:
Examples¶
# No arguments
echo '{}' | jpx 'now()'
# One argument
echo '{"name": "hello"}' | jpx 'upper(name)'
# Multiple arguments
echo '{"text": "hello world"}' | jpx 'split(text, ` `)'
# Literal arguments (use backticks)
echo '{}' | jpx 'range(`1`, `10`)'
Standard vs Extension Functions¶
Standard Functions (26)¶
These are part of the JMESPath specification and work in all implementations:
abs, avg, ceil, contains, ends_with, floor, join, keys, length, map, max, max_by, merge, min, min_by, not_null, reverse, sort, sort_by, starts_with, sum, to_array, to_number, to_string, type, values
Extension Functions (369)¶
These are jpx-specific and won't work in other JMESPath implementations.
Strict Mode¶
Use --strict to disable extension functions: