"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.GetStepJsonToolDefinition = exports.getStepJsonResponseSchema = exports.getStepJsonParamsSchema = void 0;
var zod_1 = require("zod");
var toolDefinition_js_1 = require("../toolDefinition.js");
var agentToolNames_js_1 = require("../shared/agentToolNames.js");
exports.getStepJsonParamsSchema = zod_1.z.object({
    step_ids: zod_1.z.array(zod_1.z.string()).min(1).meta({
        description: 'Stable canonical step ids (from get_test_context) of the steps to read. Returns each step as raw json_steps so you can edit a field while preserving the rest of the descriptor — in particular the recorded find with all its captured attributes.',
    }),
});
exports.getStepJsonResponseSchema = zod_1.z.object({
    steps: zod_1.z.array(zod_1.z.object({
        step_id: zod_1.z.string(),
        found: zod_1.z.boolean().meta({
            description: 'False when no root-level step with this id exists.',
        }),
        json: zod_1.z.string().optional().meta({
            description: 'The step in json_steps form (single-key object keyed by step type), JSON-encoded. Present only when found.',
        }),
    })),
});
exports.GetStepJsonToolDefinition = (0, toolDefinition_js_1.defineTool)({
    name: agentToolNames_js_1.AgentToolNames.GetStepJson,
    description: 'Returns the raw json_steps JSON for existing steps by step_id, so you can read a step before editing it with execute_edit_steps. Read the step first whenever you are changing one field (e.g. a find/selector or entered text) so you can edit in place and keep the recorded find descriptor and its captured attributes intact rather than re-authoring a thinner selector. Root-level steps only.',
    argumentsSchema: exports.getStepJsonParamsSchema,
    responseSchema: exports.getStepJsonResponseSchema,
});
//# sourceMappingURL=GetStepJsonDefinition.js.map