Wire contract reference
The wire between the Roboticks SDK and the Roboticks platform is JUnit XML extended withroboticks.* properties, converted server-side to a canonical JSON document. This page is the authoritative reference. For the tutorial introduction, see Testing → Wire contract.
Schema version
The wire contract is versioned as a single integer. Currently2.
Version policy
v2 changes vs v1
- Added (required when emitted):
roboticks.nodeidon every<testcase>— the pytest nodeid, used by the platform to deterministically route per-test-case artifacts into the S3 prefixtest-runs/{run_id}/test-cases/{sha256(nodeid)[:16]}/. - Added (optional, repeatable):
roboticks.attach.{kind}— one property per file registered viaroboticks.attach_artifact(). The property name carries the kind (mcap,logs,attachments, or any custom single-segment label) and the value is the local file path; the runner uploader walks these and posts each file to the per-test-case prefix. - Behavior: schema-1 uploads still parse — the platform falls back to a run-level prefix when
roboticks.nodeidis absent. Schema-2 readers tolerate the absence ofroboticks.attach.*(it just means the test did not callattach_artifact).
Suite-level properties
Test-case properties
roboticks.attach.{kind} — per-test artifact attachments
Schema 2 adds a property family for files a test registers via attach_artifact(). The property name carries the kind, the value carries the local path:
The runner walks
<testcase> for every property whose name starts with roboticks.attach. and posts the file to the platform’s /test-runs/{run_id}/mcap-upload-urls endpoint with {nodeid, kind} in the body. The backend lands it at:
JUnit XSD excerpt
schemas/junit_with_confirms.xsd in the SDK repo. Validate locally:
Canonical test-result JSON
The platform converts JUnit-with-confirms into this JSON shape:nodeid_slug is sha256(nodeid).hexdigest()[:16] — derived deterministically on both the SDK and the platform so the per-test-case S3 prefix is stable across re-runs without round-tripping the slug through the wire.
JSON Schema (excerpt):
schemas/test_result.schema.json.
Forward / backward compatibility
The platform supports the current and one-back schema versions (v2 and v1 today).
Disagreement handshake
When the SDK and the platform disagree on schema version, the platform writes aroboticks.platform.warnings element into the run’s metadata:
What the SDK guarantees
- A given SDK release pins to exactly one schema version.
- Within a major SDK series (e.g. all
0.x.y), the schema version doesn’t decrease. - The XSD and JSON Schema files in the SDK repo at a tag are the authoritative artefacts for that release.
What the platform guarantees
- Backwards-compat for at least the current and one-back schema versions.
- Forward-tolerance: unknown
roboticks.*properties are dropped, not rejected. - The conversion from XML to canonical JSON is documented and stable per schema version.
Tools
Next
Wire contract tutorial
The version-handshake story in narrative form.
Pytest plugin
Reference for the writer.
C++ reference
Reference for the C++ writer.
Schemas in the SDK repo
Source of truth.