Constructive typed-schema fixture composer
Compose a complete bounded basis of valid fixture values with per-goal coverage or unavailability under a small typed JSON Schema profile.
api-assurance · Operation ID: json-schema-fixtures-compose
Choose this operation when
- generate valid boundary request bodies from a supported typed JSON schema
- compose goal-labelled schema fixtures for a caller-run validator harness
Outside this profile
- Exhaustive input-space, every property combination or every array-position coverage
- Counterexamples proving schema compatibility or arbitrary satisfiability search
- Arbitrary JSON Schema, formats, regexes, references, combinators, nested objects or nested arrays
- Executing target tests, fetching services, running supplied code or proving security
Exact release references
Static JSON contract · Markdown reference · Fixed example response
Complete input schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"schema": {
"$ref": "#/$defs/__schema0"
}
},
"required": [
"schema"
],
"additionalProperties": false,
"$defs": {
"__schema0": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"items": {
"$ref": "#/$defs/__schema0"
}
},
{
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"$ref": "#/$defs/__schema0"
}
}
]
}
}
}
Complete output-envelope schema
{
"type": "object",
"required": [
"operation",
"version",
"result",
"provenance"
],
"properties": {
"operation": {
"const": "json-schema-fixtures-compose",
"type": "string"
},
"version": {
"const": "0.29.0",
"type": "string"
},
"result": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"profile": {
"type": "string",
"const": "constructive-json-schema-v1"
},
"status": {
"type": "string",
"enum": [
"complete",
"unsatisfiable"
]
},
"fixtures": {
"maxItems": 128,
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"value": {
"$ref": "#/properties/result/$defs/__schema0"
},
"goalIds": {
"maxItems": 512,
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"id",
"value",
"goalIds"
],
"additionalProperties": false
}
},
"goals": {
"maxItems": 512,
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"kind": {
"type": "string"
},
"instancePath": {
"type": "string"
},
"schemaPath": {
"type": "string"
},
"status": {
"type": "string",
"enum": [
"covered",
"unavailable"
]
},
"fixtureIds": {
"maxItems": 128,
"type": "array",
"items": {
"type": "string"
}
},
"reason": {
"type": [
"string",
"null"
]
}
},
"required": [
"id",
"kind",
"instancePath",
"schemaPath",
"status",
"fixtureIds",
"reason"
],
"additionalProperties": false
}
},
"reason": {
"anyOf": [
{
"type": "object",
"properties": {
"code": {
"type": "string"
},
"schemaPath": {
"type": "string"
},
"message": {
"type": "string"
}
},
"required": [
"code",
"schemaPath",
"message"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"testing": {
"type": "object",
"properties": {
"targetExecuted": {
"type": "boolean",
"const": false
},
"behaviorVerified": {
"type": "boolean",
"const": false
},
"fullInputSpaceCoverage": {
"type": "boolean",
"const": false
}
},
"required": [
"targetExecuted",
"behaviorVerified",
"fullInputSpaceCoverage"
],
"additionalProperties": false
},
"metrics": {
"type": "object",
"properties": {
"schemaNodes": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"validatorNodeVisits": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"schemaNodes",
"validatorNodeVisits"
],
"additionalProperties": false
}
},
"required": [
"profile",
"status",
"fixtures",
"goals",
"reason",
"testing",
"metrics"
],
"additionalProperties": false,
"$defs": {
"__schema0": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "null"
},
{
"type": "array",
"items": {
"$ref": "#/properties/result/$defs/__schema0"
}
},
{
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"$ref": "#/properties/result/$defs/__schema0"
}
}
]
}
}
},
"provenance": {
"type": "object",
"required": [
"inputSha256",
"outputSha256",
"deterministic",
"externalRequests"
],
"properties": {
"inputSha256": {
"type": "string",
"pattern": "^[a-f0-9]{64}$"
},
"outputSha256": {
"type": "string",
"pattern": "^[a-f0-9]{64}$"
},
"deterministic": {
"const": true
},
"externalRequests": {
"const": 0
}
}
}
},
"additionalProperties": false
}
Fixed example
One accepted fixed example, not a custom-input trial. No operation runs when this static page is requested.
Example input
{
"schema": {
"type": "object",
"required": [
"count",
"mode"
],
"properties": {
"count": {
"type": "integer",
"minimum": 1,
"maximum": 3
},
"mode": {
"type": "string",
"enum": [
"fast",
"safe"
]
}
},
"additionalProperties": false
}
}
Example response
{
"operation": "json-schema-fixtures-compose",
"version": "0.29.0",
"result": {
"profile": "constructive-json-schema-v1",
"status": "complete",
"fixtures": [
{
"id": "f001",
"value": {
"count": 1,
"mode": "fast"
},
"goalIds": [
"g001",
"g002",
"g004"
]
},
{
"id": "f002",
"value": {
"count": 3,
"mode": "fast"
},
"goalIds": [
"g003"
]
},
{
"id": "f003",
"value": {
"count": 1,
"mode": "safe"
},
"goalIds": [
"g005"
]
}
],
"goals": [
{
"id": "g001",
"kind": "baseline",
"instancePath": "",
"schemaPath": "",
"status": "covered",
"fixtureIds": [
"f001"
],
"reason": null
},
{
"id": "g002",
"kind": "minimum",
"instancePath": "/count",
"schemaPath": "/properties/count/minimum",
"status": "covered",
"fixtureIds": [
"f001"
],
"reason": null
},
{
"id": "g003",
"kind": "maximum",
"instancePath": "/count",
"schemaPath": "/properties/count/maximum",
"status": "covered",
"fixtureIds": [
"f002"
],
"reason": null
},
{
"id": "g004",
"kind": "enum:0",
"instancePath": "/mode",
"schemaPath": "/properties/mode/enum",
"status": "covered",
"fixtureIds": [
"f001"
],
"reason": null
},
{
"id": "g005",
"kind": "enum:1",
"instancePath": "/mode",
"schemaPath": "/properties/mode/enum",
"status": "covered",
"fixtureIds": [
"f003"
],
"reason": null
}
],
"reason": null,
"testing": {
"targetExecuted": false,
"behaviorVerified": false,
"fullInputSpaceCoverage": false
},
"metrics": {
"schemaNodes": 3,
"validatorNodeVisits": 17
}
},
"provenance": {
"inputSha256": "00ed529a30f8458abb6580d8672e529443e30ca8741a90bda07d2153fad821f4",
"outputSha256": "022438b15adb78e88f4cbcea2f92851f0f87f5b974e69d887628681ed5ad10d1",
"deterministic": true,
"externalRequests": 0
}
}
Bounds and precision
JavaScript IEEE-754 numbers; use strings for large integer IDs/exact decimals where the schema accepts strings. No lossless numeric parsing.
{
"global": {
"requestBytes": 131072,
"responseBytes": 524288,
"jsonDepth": 32,
"jsonNodes": 20000,
"requestsPerMinute": 60,
"paidAttemptsPerMinute": 20,
"idempotencyHours": 24
},
"operation": {
"inputBytes": 100000,
"outputBytes": 300000,
"inputNodes": 12000,
"outputNodes": 50000,
"depth": 16,
"schemaNodes": 80,
"properties": 32,
"enumMembers": 16,
"arrayItems": 16,
"stringLength": 256,
"fixtures": 128,
"goals": 512,
"mutations": 64,
"validatorNodeVisits": 50000,
"candidateBytes": 2000000,
"jsonNodes": 12000,
"profile": "constructive-json-schema-v1"
}
}
Complete schemas, descriptions and cross-field validation may impose additional limits.
Proposed price and protocol definitions
{
"unit": "one successful operation call",
"proposedNominalUsd": "0.005",
"sixDecimalTokenBaseUnits": "5000",
"subscription": false,
"includesPayerWalletOrNetworkFees": false,
"liveQuoteVerified": false,
"condition": "Actual SDK challenge is authoritative only within the caller's explicit authorization; configured six-decimal token peg is an operator assertion, not a conversion guarantee."
}
Protocol definitions: x402, mpp. MPP uses Tempo charge. Paid MCP execution is unsupported. All runtime readiness is not evaluated in this build.
API path templates, not endpoints on this documentation host
{
"x402": "/v1/x402/json-schema-fixtures-compose",
"mpp": "/v1/mpp/json-schema-fixtures-compose"
}
Required headers
{
"Content-Type": "application/json",
"Idempotency-Key": "random 16–128 character operation identifier"
}
Actual SDK challenge amount, asset, network, recipient and wallet costs must pass independent authorization. Preserve identical key, body, protocol and credential on retries; on PAYMENT_UNCERTAIN stop and reconcile.
Execution profile and provider conditions
{
"deterministic": true,
"externalRequests": 0,
"maxExternalRequests": 0,
"resultSnapshotPersisted": false,
"fixedExampleIsIllustrativeSnapshot": false,
"requiresPayment": true,
"supportsMcpExecution": false
}
Deterministic supplied-input operation with no external requests or stored request/result bodies. Payment infrastructure retains payment metadata and hashes.
Failure handling
- HTTP 400: Malformed JSON, missing/invalid idempotency key, or payment identifier mismatch Correct the request before payment
- HTTP 402: Payment challenge or rejected payment Use official protocol SDK; inspect payment outcome before another payment
- HTTP 409: Idempotency conflict, duplicate proof, or PAYMENT_UNCERTAIN Keep original key, body, and proof; reconcile uncertainty with operator; never blindly repay
- HTTP 413: Input or generated output too large Reduce input; no payment attempted for validation failure
- HTTP 415: Unsupported media type or compression Send uncompressed application/json
- HTTP 422: Schema or service-specific semantic validation failure Correct input using returned error code; no payment attempted
- HTTP 429: Request/payment-attempt rate exceeded Wait for rate limit window; preserve existing payment identity
- HTTP 503: Payment configuration/provider/state unavailable, or live DNS preparation failed before settlement Check readiness; DNS preparation failures may retry the identical key/body/credential only; uncertainty requires reconciliation
Declared requirements
Before any paid call, refresh the live operation contract and POST the complete bounded budgeted plan to the separate API's /preflight. Unknown requirements block selection; compatible preflight is not permission to spend.