JSON::...tation(3pm)

πŸ“¦
version 0.642 Β· 4 versions
, in ubuntu stonking

✨ NAME ✨

JSON::Schema::Modern::Vocabulary::FormatAnnotation β€” okay so this is the implementation of the JSON Schema Format-Annotation vocabulary πŸ’… and yes bestie, it lives in section 3pm of the User Contributed Perl Documentation, so you already know it's giving real-deal module energy.


🌸 VERSION 🌸

version 0.642

Not me using a linearly-increasing version numbering scheme β€” no meaning should be presumed or inferred from the version being less than 1.0. Like, it's not a baby module just because it's a 0-dot-something, ok?? πŸ™ˆ


πŸ¦‹ DESCRIPTION πŸ¦‹

So this is the implementation of the JSON Schema Draft 2020-12 "Format-Annotation" vocabulary, which gets indicated in metaschemas with the URI https://json-schema.org/draft/2020-12/vocab/format-annotation and is formally specified over at https://json-schema.org/draft/2020-12/json-schema-validation.html#section-7. Periodt.

And it's not just one draft, she's versatile πŸ’… β€” support is also provided for:

Iconic behaviour, truly. πŸŽ€

It also implements format assertion behaviour in a relaxed mode, meaning the validate_formats option in JSON::Schema::Modern has been enabled, and unknown formats will not generate errors. Which is lowkey the opposite vibe from the more strict behaviour in JSON::Schema::Modern::Vocabulary::FormatAssertion, which requires all formats used in the schema to be supported and defined. Strict queen vs. chill queen, you know how it is. 😌

Now listen closely because this part is the actual tea β˜• β€” when this vocabulary (the Format-Annotation vocabulary) is specified (which, btw, is the default for the draft2020-12 metaschema) and combined with the validate_formats option set to true, then:

  • unimplemented formats will silently validate 🀫
  • but implemented formats will validate completely πŸ’―
Heads up bestie: some formats require optional module dependencies, and the lack of these modules will generate an error. So don't come crying to me if you skipped the optional deps, I warned you fr fr 😭

And when the Format-Assertion vocabulary is specified, unimplemented formats will generate an error on use. No silent validating over there, she's calling you out directly. πŸ’€


πŸ‘€ SEE ALSO πŸ‘€

  • "Format Validation" in JSON::Schema::Modern
  • JSON::Schema::Modern::Vocabulary::FormatAssertion

🫢 GIVING THANKS 🫢

If you found this module to be useful, please show your appreciation by adding a +1 in MetaCPAN https://metacpan.org/dist/JSON-Schema-Modern and a star in GitHub https://github.com/karenetheridge/JSON-Schema-Modern. It costs you literally nothing and it makes someone's whole day, bestie. It's giving mutual support. πŸ’–


🧚 SUPPORT 🧚

Bugs may be submitted through https://github.com/karenetheridge/JSON-Schema-Modern/issues. Found a bug? Tell her, don't suffer in silence πŸ™ˆ

I am also usually active on irc, as ether at irc.perl.org and irc.libera.chat. Come say hi!!

You can also find me on the JSON Schema Slack server https://json-schema.slack.com and OpenAPI Slack server https://open-api.slack.com, which are also great resources for finding help. Real ones know. ✨


πŸ‘‘ AUTHOR πŸ‘‘

Karen Etheridge <ether@cpan.org>


This software is copyright (c) 2020 by Karen Etheridge.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.

Some schema files have their own licence, in share/LICENSE. Check those, bestie, don't just assume πŸ“


And that's the whole page, no cap β€” brought to you by perl v5.40.1, dated 2026-07-31, from your favourite JSON::...tation(3pm) manual. Slay, stay validating, and hydrate πŸ’…πŸ’–βœ¨

πŸ“¦ where this page comes from