v2 binding generators
These examples show the same v2 binding contract generated from several language-native declaration styles:
js/- plain JavaScript helper, no transpilernodejs/- Node.js script that writes a binding documentts/- TypeScript decorator-style declarationphp/- PHP 8 attribute + reflectiongo/- Go typed descriptors and struct-like field definitionsc/- C static descriptor emitting the same JSON contract
All examples generate the same shape:
{
"version": "urirun.bindings.v2",
"bindings": {
"scheme://target/resource/operation": {
"kind": "command",
"adapter": "argv-template",
"inputSchema": {},
"argv": []
}
}
}
The runtime does not care which language generated the file. It only consumes the v2 JSON contract.
Run from the repository root:
./run_tests.sh
The smoke tests execute every installed language generator and validate the generated binding document through urirun validate.
For the shorter convention-based style, see ../13-simple_defaults: it declares the connector once and then uses short route paths in Python and JavaScript.