Integration

API / SDK Integration Guide

Use these integration notes to wire ISON into backend services, prompt pipelines, and validation gates.

Python SDK

Install package and parse ISON before prompt assembly.

pip install ison

from ison import loads

doc = loads(ison_text)
data = doc.to_dict()

JavaScript / TypeScript SDK

Use parser utilities for conversion and validation.

npm install ison-js

import { loads, jsonToISON } from 'ison-js';

const isonText = jsonToISON(jsonPayload);
const doc = loads(isonText);

HTTP API pattern

Recommended endpoint contract for conversion services.

POST /v1/convert
{
  "direction": "json_to_ison",
  "payload": { ... }
}

Validation gate pattern

Run syntax validation before persisting prompt context assets.

if not is_valid_ison(payload):
    raise ValueError("Invalid ISON")
save_context_block(payload)

Deployment notes

  • Keep conversion and validation in the same pipeline stage.
  • Track token savings in observability metrics.
  • Version your ISON schema changes with release tags.
  • Retain JSON fallback for legacy consumers.

Try before integrating

Run your payload through Converter and Validator pages, then wire SDK calls into services.