Skip to content

[Feature]: Expose workspacePreparedAt in openclaw code run --json output #112

@zhyongrui

Description

@zhyongrui

Summary
Add one stable top-level string field to openclaw code run --json named workspacePreparedAt.

Problem to solve
Downstream tooling currently has to inspect workspace.preparedAt directly just to read this nested string value. That is awkward for simple JSON consumers.

Proposed solution
Update src/commands/openclawcode.ts so the JSON output includes workspacePreparedAt: string | null.

  • set it to the nested workspace.preparedAt value when present
  • otherwise emit null

Add or adjust unit tests in src/commands/openclawcode.test.ts to cover both cases.

Impact
Affected users/systems/channels
Tools and scripts that read openclaw code run --json.

Severity
Low.

Frequency
Whenever downstream tooling wants this string value without unpacking nested workflow metadata.

Consequence
Without the derived field, simple consumers keep reimplementing the same nested null-check logic.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions