Agent skill

Jsonlogic

by aiskillstore in aiskillstore/marketplace

Work with JsonLogic business rules — the JSON-based conditional-logic format at jsonlogic.com.

MITAuto-check passedProduct & Project Management

Install Jsonlogic

skills CLI
$ npx skills add aiskillstore/marketplace --skill jsonlogic -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install aiskillstore/marketplace jsonlogic --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/aiskillstore/marketplace.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/valeryia-piatrova/jsonlogic .claude/skills/jsonlogic && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
jsonlogic
GitHub stars
430
Token cost
~2.8k tokens
SKILL.md length
1,351 words
Files
77 (incl. scripts, references, assets)
Skills in repo
1,108
Repo updated
First seen
Licence
MIT

At a glance

Work with JsonLogic business rules — the JSON-based conditional-logic format at jsonlogic.com.

  • Works in 6 steps: Read assets/playground.html. It's a… → Replace INITIAL_RULE and INITIAL_DATA… → Replace CURRENT_LANG_MODE with "ruby"… → …
  • The user wants to turn a business requirement into a JsonLogic rule
  • SKILL.md covers Running JsonLogic, Playground artifact, Writing JsonLogic and Validate JsonLogic, plus 3 more sections
  • Runs JavaScript scripts from its folder

What it does

Jsonlogic is an agent skill from aiskillstore/marketplace. Work with JsonLogic business rules — the JSON-based conditional-logic format at jsonlogic.com. Use whenever the user wants to turn a business requirement into a JsonLogic rule, needs an existing JsonLogic expression explained or debugged, asks whether a rule is valid, wants to execute JsonLogic in a specific language (JavaScript, TypeScript, Python, Ruby, Java, PHP, Go, C, others), is choosing or comparing a JsonLogic library, or is integrating JsonLogic into an application. Trigger on mentions of JsonLogic…

Its SKILL.md is about 2.8k tokens, which your agent loads only when the skill is triggered. The skill folder holds 81 other files, including scripts, reference files and assets (for example `.claude-plugin/marketplace.json`, `.claude-plugin/plugin.json` and `CHANGELOG.md`).

It sits in Product & Project Management, covering PRD writing. It works with JavaScript, Python, Ruby and C#. The repository describes itself as: Security-audited skills for Claude, Codex & Claude Code. One-click install, quality verified. The licence is MIT.

When your agent uses it

  • The user wants to turn a business requirement into a JsonLogic rule
  • Needs an existing JsonLogic expression explained
  • Asks whether a rule is valid
  • Wants to execute JsonLogic in a specific language (JavaScript

Example prompts

  • “/jsonlogic”

Requirements

  • Python 3
  • Node.js

Workflow steps

6 steps, taken from the first numbered list in SKILL.md.

  1. Read assets/playground.html. It's a fixed-design page (rule, live result, data) —
  2. Replace INITIAL_RULE and INITIAL_DATA with the rule/data objects, each as
  3. Replace CURRENT_LANG_MODE with "ruby" when the target language is Ruby,
  4. Replace VERIFY_LIB_LABEL with the same library Running JsonLogic → Library
  5. Write the result to a working file and publish it — the first time in a
  6. Whenever the rule, data, or language changes later in the same conversation, redo

What it can do on your machine

Read from SKILL.md and the folder at commit ad8daf7. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    Ships 1 file in scripts/ (JavaScript, from the files we listed), which the agent can run.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • jsonlogic.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Jsonlogic loads about 2.8k tokens when it runs, and up to ~67k if it reads all its reference files. Until then it costs about 183 tokens; SKILL.md has 1,351 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~183
When it runs · the whole SKILL.md, loaded when a task matches
~2.8k
With references · SKILL.md plus every file in references/, read only if the agent opens them
~67k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); the scripts in this folder are not scanned.

SKILL.md

The full file from aiskillstore/marketplace at commit ad8daf7, republished under its MIT licence (© aiskillstore). 1,351 words, ~2,750 tokens.

Download SKILL.mdSave it as .claude/skills/jsonlogic/SKILL.md (or your agent's skills folder). This skill also uses 76 other files; get the full folder from GitHub.
name
jsonlogic
description
Work with JsonLogic business rules — the JSON-based conditional-logic format at jsonlogic.com. Use whenever the user wants to turn a business requirement into a JsonLogic rule, needs an existing JsonLogic expression explained or debugged, asks whether a rule is valid, wants to execute JsonLogic in a specific language (JavaScript, TypeScript, Python, Ruby, Java, PHP, Go, C#, others), is choosing or comparing a JsonLogic library, or is integrating JsonLogic into an application. Trigger on mentions of JsonLogic, json-logic, JSON rule objects shaped like {"var": ...}, or requests to express conditions and business rules as portable JSON. Do not use for general programming tasks that don't involve the JsonLogic format.

JsonLogic

A skill for work with JsonLogic.

JsonLogic is a small, portable format for expressing conditional logic as JSON.

The JsonLogic standard is the universal rule format and defines its semantics. A rule at this level is language-agnostic. See references/jsonlogic.md and references/operations.md.

A specific library is the code that executes JsonLogic in a particular language, such as json-logic-js for JavaScript or json-logic-rb for Ruby. Libraries can differ in the operations they support, as well as their API shape and error handling.

Running JsonLogic

Library

If a specific implementation is named, such as json-logic-js, use that exact implementation. A language name alone, such as “in Python”, means use the library for that language from references/libraries.md. If neither a library nor a language is named, default to scripts/jsonlogic.rb.

Support

A rule can be valid JsonLogic and still be unsupported by the selected library or its current version. Flag unsupported operations. Never rewrite a valid JsonLogic rule just because one library can't run it. Say which level the limitation is at and offer the real options:

  • a custom operation
  • a different library if operation is not supported in specific implementation
  • logic change

Playground artifact

Whenever a concrete rule is in play (created, explained, fixed, or executed), render it live instead of only describing it in text: seed assets/playground.html with that rule and data, then publish it with the Artifact tool. This runs under whoever installed the skill — each publish call creates the artifact under that person's own account, so it works the same way for every installer with no sharing step needed. The artifact is private by default, and publishing here just updates the same URL, so there's no separate decision to check on each time.

Two files, one static and one templated: assets/jsonlogic-core.js is the JsonLogic interpreter — it never changes between invocations, so publish it once per conversation (via the Artifact tool's files param) and never again. assets/playground.html is the thin page with the placeholders below; it's the only one that gets re-templated and republished on every change.

  1. Read assets/playground.html. It's a fixed-design page (rule, live result, data) — never hand-edit its CSS/layout; only the placeholders below change per invocation.
  2. Replace __INITIAL_RULE__ and __INITIAL_DATA__ with the rule/data objects, each as a JS/JSON literal (the output of JSON.stringify(...), valid to drop in as-is). No concrete rule yet → leave both untouched, the template falls back to a built-in default.
  3. Replace __CURRENT_LANG_MODE__ with "ruby" when the target language is Ruby, otherwise "jsonlogic" (every other language shown here follows JsonLogic's own truthy/falsy rules; only Ruby's diverge). No language decided yet → leave it untouched, falls back to "jsonlogic".
  4. Replace __VERIFY_LIB_LABEL__ with the same library Running JsonLogic → Library (above) resolved to for this task — this is what the page's "Verify in chat" button names when asking to confirm against the real implementation, so it must match, not default to Ruby just because that's this file's own fallback:
    • Ruby → "json-logic-rb (scripts/jsonlogic.rb)"
    • JavaScript / TypeScript → "json-logic-js"
    • Python → "maykin-json-logic-py"
    • Java → "json-logic-java"
    • PHP → "json-logic-php (jwadhams/json-logic-php)"
    • Go → "diegoholiveira/jsonlogic"
    • C# / .NET → "JsonLogic (json-everything)"
    • Any other language from references/libraries.md → that library's name as given there. No language/library decided yet → leave it untouched, falls back to Ruby's "json-logic-rb (scripts/jsonlogic.rb)", matching this skill's own default.
  5. Write the result to a working file and publish it — the first time in a conversation: Artifact tool, action:"publish", that file's path, title:"JSON Logic Playground", icon:"code", plus files:{"jsonlogic-core.js":"assets/jsonlogic-core.js"} so the interpreter ships alongside it unmodified.
  6. Whenever the rule, data, or language changes later in the same conversation, redo steps 1–4 with the new values and publish again with the same file path and the same url — but omit files this time, since jsonlogic-core.js never changes and an omitted file is kept as-is. This updates the same artifact in place instead of creating a new one.

Skip this for requests that never produce a concrete rule (e.g. "what does missing do").

The user can edit the rule/data directly in the artifact to test things — that's the point, it recalculates live. Never republish over those manual edits. Only republish when the user asks for a new or changed rule/condition in chat.

Writing JsonLogic

Step 1: Get the data shape

Always ask how to get the data’s field names before creating a new rule. Present this as choice. Use the client’s structured question mechanism, such as buttons or a picker, when available. Otherwise, present the choices as plain text.

Question: "How should I get your data's field names?". Offer three options:

  • Option Schema — "I'll paste a schema — JSON Schema, OpenAPI, whatever format."
  • Option Sample data — "I'll paste a real JSON example."
  • Option Just guess — "Infer field names from my description."

The dialog only picks the method. The actual answer still comes as a normal follow-up message, not inside the dialog itself.

Step 2: Build the expression

Write the rule using the field names from Step 1.

Before writing a new rule, check references/operations.md for the full supported list and examples/ for worked patterns. For real upstream test cases per operator, see references/tests/.

Show full SKILL.md (520 more words)Show less
Customization

Don’t expect JsonLogic to include every specialized operation. It’s intentionally small and not a programming language. It will never do everything. However JsonLogic support extentions. Before you reach for a custom solution, see if you can express your logic using the supported operations (built-in). Often, a simple change in perspective is all you need to get the job done with what's already there.

Step 3: Explain what it does

Cover:

  • the requirement being encoded
  • the operations used and what each does
  • the expected input shape
  • what the rule returns
  • edge cases worth flagging (missing fields, type coercion, empty arrays)

Skip items that don't apply.

Missing information

If business condition unclear – you should ask what the rule should check, but don't ask about things you can already resolve from context.

Validate JsonLogic

Checking shape against references/jsonlogic.md, references/operations.md, or scripts/validate_skill.rb only confirms the rule is shaped like JsonLogic.

Real validation means writing test cases and running them through scripts/jsonlogic.rb. See references/testing.md for how to pick them. Cover the normal case and the boundary, but weight it toward edge cases especially: missing fields, empty arrays, unexpected types. A rule with no test cases isn't safe to hand off — there's no way to guarantee it behaves as expected.

For the individual operators a rule uses, check references/tests/ first — real upstream cases for both the core spec (core.json) and the community extensions (community/), bundled locally. Reuse a matching case as a sanity check before writing new ones from scratch; these test the operators in isolation, not the rule's actual business logic, so still add rule-specific cases on top.

Debug JsonLogic

Step 1: Reproduce it

Use Running JsonLogic with the rule and data as reported. See the actual output yourself before diagnosing anything.

Step 2: Find the actual cause

Lead with the real cause, not just the symptom — common culprits: type coercion, missing fields, operator misuse.

Step 3: Fix and verify

Give the corrected rule, then re-run Step 1 with the fix to confirm the new output is right. If the fix needs to be handed back as runnable code, continue to Execute JsonLogic below.

After any

Verify running

See Running JsonLogic above to actually execute the rule. If there's no data example on hand yet, create a representative one first. Verifying needs real input to run against, not just a description of what the rule should do.

Flag concerns

Don't claim JsonLogic is "safe" just because it's JSON.

Reference files

Read these as needed rather than loading everything up front:

  • references/jsonlogic.md — core semantics: truthiness, type coercion, var path resolution, how missing data behaves, what "compliant" means.
  • references/operations.md — every standard operation: syntax plus behavior notes worth knowing (short-circuiting, three-argument comparisons, reduce's current/accumulator, etc).
  • references/libraries.md — the library landscape across languages: what was found, what was verified, what wasn't. Read before writing any language-specific code, including for languages not listed — check there first rather than assuming none exists.
  • references/testing.md — how to verify a rule or implementation, and how to be honest about what "verified" means in a given answer.
  • references/tests/ — bundled upstream test cases (core spec + community extensions) for validating individual operators.
  • examples/ — worked examples:

© aiskillstore, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

SKILL.md and 76 other files (scripts, references, assets) in skills/valeryia-piatrova/jsonlogic of aiskillstore/marketplace.

  • SKILL.md
  • .claude-plugin/marketplace.json
  • .claude-plugin/plugin.json
  • CHANGELOG.md
  • LICENSE
  • README.md
  • assets/demo.gif
  • assets/jsonlogic-core.js
  • assets/playground.html
  • docs/installing.md
  • examples/basic-rules.json
  • examples/conditions.json
  • references/jsonlogic.md
  • references/libraries.md
  • references/operations.md
  • references/testing.md
  • … and 61 more

Open the folder on GitHubat commit ad8daf7

Compare with similar skills

Jsonlogic next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Jsonlogic compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Jsonlogic this skillaiskillstore/marketplace430—~2.8kAutomated safety check: PassMIT
Crap Analyzerswingerman/engineer154—~1.2kAutomated safety check: PassMIT
Security Reviewgithub/awesome-copilot40k1 repos~2.3kAutomated safety check: NotesMIT
Selenium Skillsickn33/agentic-awesome-skills47k1 repos~2.4kAutomated safety check: PassMIT
Detecting Eval Exec Usagejeremylongshore/tons-of-skills-marketplace2.8k—~1.1kAutomated safety check: PassMIT
Code Audit3stoneBrother/code-audit8931 repos~2.7kAutomated safety check: PassNone

Similar skills

  • Crap Analyzer

    swingerman/engineer

    A skill your agent uses to produce a risk-based refactor + test plan for recently-changed code on a diff/branch/PR by computing CRAP (complexity × untested) on changed methods.

    154 GitHub stars~1.2k tokensUpdated 15 days ago
    Testing & QAAuto-check passed
  • Security Review

    github/awesome-copilot

    Official

    AI-powered codebase security scanner that reasons about code like a security researcher — tracing data flows, understanding component interactions, and catching vulnerabilities that pattern-matching…

    40k GitHub starsUsed in 1 repo~2.3k tokens
    SecurityAuto-check: notes
  • Selenium Skill

    sickn33/agentic-awesome-skills

    Generates production-grade Selenium WebDriver automation scripts and tests in Java, Python, JavaScript, C, Ruby, or PHP.

    47k GitHub starsUsed in 1 repo~2.4k tokens
    Testing & QAAuto-check passed
  • Detecting Eval Exec Usage

    jeremylongshore/tons-of-skills-marketplace

    Scan a source tree for dynamic-code-execution APIs that an attacker can hijack: Python eval / exec / compile, JavaScript eval / Function() / setTimeout(string), Ruby eval / instanceeval / classeval…

    2.8k GitHub stars~1.1k tokensUpdated today
    Testing & QAAuto-check passed
  • Code Audit

    3stoneBrother/code-audit

    Professional code security audit skill covering 55+ vulnerability types.

    893 GitHub starsUsed in 1 repo~2.7k tokens
    SecurityAuto-check passed
  • Run profile-driven bottleneck optimization across Apache Fory implementations (Java, C++, Python/Cython, Go, Rust, Swift, C, JavaScript/TypeScript, Dart, Kotlin, Scala).

    4.6k GitHub stars~2.2k tokensUpdated yesterday
    MobileAuto-check passed

More from aiskillstore/marketplace

All 1,108 skills in this repo
  • Code Stats

    aiskillstore/marketplace

    Analyze codebase with tokei (fast line counts by language) and difft (semantic AST-aware diffs).

    430 GitHub starsUsed in 2 repos~697 tokens
    Auto-check: notes
  • File Search

    aiskillstore/marketplace

    Modern file and content search using fd, ripgrep (rg), and fzf.

    430 GitHub starsUsed in 2 repos~598 tokens
    Auto-check: notes
  • Data Processing

    aiskillstore/marketplace

    Process JSON with jq and YAML/TOML with yq. An agent skill from aiskillstore/marketplace.

    430 GitHub starsUsed in 1 repo~720 tokens
    Auto-check: notes
  • Doc Scanner

    aiskillstore/marketplace

    Scans for project documentation files (AGENTS.md, CLAUDE.md, GEMINI.md, COPILOT.md, CURSOR.md, WARP.md, and 15+ other formats) and synthesizes guidance.

    430 GitHub starsUsed in 1 repo~644 tokens
    Auto-check: notes
  • Find Replace

    aiskillstore/marketplace

    Modern find-and-replace using sd (simpler than sed) and batch replacement patterns.

    430 GitHub starsUsed in 1 repo~527 tokens
    Auto-check: notes
  • Investigating Codebases

    aiskillstore/marketplace

    Automatically activated when user asks how something works, wants to understand unfamiliar code, needs to explore a new codebase, or asks questions like "where is X implemented?", "how does Y…

    430 GitHub starsUsed in 1 repo~2.7k tokens
    Auto-check: notes

Questions about Jsonlogic

What does Jsonlogic do?

Work with JsonLogic business rules — the JSON-based conditional-logic format at jsonlogic.com. Jsonlogic is an agent skill from aiskillstore/marketplace.com.

When should I use Jsonlogic?

Jsonlogic fits situations like: the user wants to turn a business requirement into a JsonLogic rule; needs an existing JsonLogic expression explained; asks whether a rule is valid; wants to execute JsonLogic in a specific language (JavaScript.

How do I install Jsonlogic in Claude Code?

Run `npx skills add aiskillstore/marketplace --skill jsonlogic -a claude-code`. Or copy the skill folder (skills/valeryia-piatrova/jsonlogic in aiskillstore/marketplace) into .claude/skills/jsonlogic in your project. Claude Code loads it when a task matches its description.

How do I install Jsonlogic in Codex?

Run `npx skills add aiskillstore/marketplace --skill jsonlogic -a codex`. Or copy the skill folder (skills/valeryia-piatrova/jsonlogic in aiskillstore/marketplace) into .agents/skills/jsonlogic in your project. Codex loads it when a task matches its description.

Can I use Jsonlogic in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add aiskillstore/marketplace --skill jsonlogic -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/jsonlogic, .gemini/skills/jsonlogic, .github/skills/jsonlogic and .opencode/skills/jsonlogic in your project.

What does Jsonlogic need to run?

Going by SKILL.md and its folder, Jsonlogic needs JavaScript for the scripts in its folder. Our summary lists: Python 3; Node.js.

Does Jsonlogic access the network?

SKILL.md names 1 domain. As links in the text: jsonlogic.com. This is read from the text; nothing was executed.

Is Jsonlogic safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. The check reads SKILL.md only: the scripts in the folder are not scanned, so read them before running anything.

What licence does Jsonlogic use?

Jsonlogic is published under the MIT licence (from the LICENSE file in the skill folder). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Jsonlogic use?

About 2.8k tokens (SKILL.md is roughly 11k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 64k tokens, read only when the agent opens those files.

What are the alternatives to Jsonlogic?

Skills that share tags, products or a category with Jsonlogic: Crap Analyzer (swingerman/engineer, 154 stars), Security Review (github/awesome-copilot, 40k stars), Selenium Skill (sickn33/agentic-awesome-skills, 47k stars) and Detecting Eval Exec Usage (jeremylongshore/tons-of-skills-marketplace, 2.8k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Jsonlogic?

aiskillstore (a GitHub organization) maintains it in aiskillstore/marketplace, which has 430 GitHub stars. The repository holds 1,108 skills in this directory. The repository was last updated on October 7, 2026.

Source: aiskillstore/marketplace on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.