Testing Saxon straight up.
For xslt3 under NPM but should also work with adjustments for Java and other (current/recent) Saxon versions.
Write a number:
xslt3 -xp:"format-integer(164,'Ww')" && echo
Write a date:
xslt3 -xp:"current-date() => format-date('[D] [MNnD3] [Y]')" && echo
JSON inputs to Saxon:
Where t.json is a json file you wish to convert to XPath JSON XML
xslt3 -json:t.json -xp:"serialize(.,map{'method':'json'}) => json-to-xml()" \!indent=yes && echo