Skip to content

Conversation

@rvwatch
Copy link
Collaborator

@rvwatch rvwatch commented Dec 8, 2025

Summary

  • Allow customers to use flat variables.json files without Variables wrapper
  • CLI automatically wraps raw variables in {Variables: ...} structure
  • Update help text to clarify new flat JSON format support

Problem

Customers' variables.json files typically contain flat JSON like:

{
    "hello": "world"
}

But the API requires variables to be wrapped in a Variables object:

{
    "Variables": {
        "hello": "world"
    }
}

This forced customers to manually restructure their files.

Solution

The CLI now automatically wraps flat variables.json content in the required Variables structure, allowing customers to use their existing files directly.

Changes

  • Modified src/commands/orchestrator/rules/eval.ts lines 148-151 to auto-wrap variables
  • Updated help documentation in messages/orchestrator.rules.eval.md
  • Maintains backward compatibility with existing variable files

Test Plan

  • All existing unit tests pass
  • All integration (NUT) tests pass
  • Linting passes
  • Manual testing with flat variables.json files works
  • Backward compatibility confirmed

- Allow customers to use flat variables.json files without Variables wrapper
- CLI automatically wraps raw variables in {Variables: ...} structure
- Update help text to clarify new flat JSON format support
- Maintains backward compatibility with existing variable files
- Improves UX by accepting customer's existing variables.json files directly
@rvwatch rvwatch merged commit 1dc5a4f into main Dec 9, 2025
14 of 15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants