OK JSON IconOK JSON
  • Overview
  • Glossary
    • Launch Screen
    • Viewer
    • Navigator
    • Editor
    • Node
    • Path Bar
    • Scripts Panel
  • Interactions
    • Drag-and-Drop
    • Toggle Nodes
    • Zoom In Node
    • Keyboard Shortcuts
    • Path Bar
    • Toolbar
    • Quick Look
  • History
  • Scripts
    • Scheme
    • API
      • Utility
      • Alert
      • Text
      • File
      • History
      • jq
      • Include
    • Examples
      • Copy As Minified JSON
      • Convert Timestamp
      • Parse XML
      • Show Text Stats
  • Integrations
    • macOS Services
    • Quick Look Extension
    • Raycast Extension
    • Apple Script
  • URL Schemes
  • Alternate Icon
  • Migration for macOS Sequoia
  • Contact Us

On This Page

  • $jq.run
Scripts
API
jq

jq

The jq protocol:

protocol JQ {
	func run(_ string: String, _ filter: String) -> String
}

Available in OK JSON 2.5+.

$jq.run

let result = $jq.run(`{"foo": 42, "bar": "less interesting data"}`, `.foo`) // 42

You can process JSON string with jq (opens in a new tab)

HistoryInclude

Copyright © 2023-2025 Anybox LTD. All rights reserved.