Skip to content

Commit b8d073a

Browse files
committed
feat: wire fixture converters into CLI as aimock convert subcommand
1 parent 5f00961 commit b8d073a

7 files changed

Lines changed: 907 additions & 601 deletions

File tree

docs/aimock-cli/index.html

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -280,6 +280,59 @@ <h2>Docker Usage</h2>
280280
</div>
281281
</div>
282282

283+
<h2>Fixture Converters</h2>
284+
<p>Convert fixtures from other mock tools to aimock format.</p>
285+
286+
<h3>Usage</h3>
287+
<div class="code-block">
288+
<div class="code-block-header">Convert fixtures <span class="lang-tag">shell</span></div>
289+
<pre><code>npx aimock convert &lt;format&gt; &lt;input&gt; [output]</code></pre>
290+
</div>
291+
292+
<h3>Supported Formats</h3>
293+
<table class="endpoint-table">
294+
<thead>
295+
<tr>
296+
<th>Format</th>
297+
<th>Source</th>
298+
<th>Description</th>
299+
</tr>
300+
</thead>
301+
<tbody>
302+
<tr>
303+
<td><code>vidaimock</code></td>
304+
<td>VidaiMock Tera templates</td>
305+
<td>
306+
Converts <code>.tera</code> / <code>.json</code> / <code>.txt</code> templates to
307+
aimock fixture JSON
308+
</td>
309+
</tr>
310+
<tr>
311+
<td><code>mockllm</code></td>
312+
<td>mock-llm YAML config</td>
313+
<td>
314+
Converts mock-llm YAML configs to aimock fixture JSON. Also extracts MCP tools if
315+
present.
316+
</td>
317+
</tr>
318+
</tbody>
319+
</table>
320+
321+
<h3>Examples</h3>
322+
<div class="code-block">
323+
<div class="code-block-header">
324+
Converter examples <span class="lang-tag">shell</span>
325+
</div>
326+
<pre><code><span class="cm"># Convert a directory of VidaiMock templates</span>
327+
$ npx aimock convert vidaimock ./templates/ ./fixtures/converted.json
328+
329+
<span class="cm"># Convert a mock-llm YAML config</span>
330+
$ npx aimock convert mockllm ./config.yaml ./fixtures/converted.json
331+
332+
<span class="cm"># Print to stdout (omit output path)</span>
333+
$ npx aimock convert vidaimock ./templates/</code></pre>
334+
</div>
335+
283336
<h2>Docker Compose</h2>
284337

285338
<div class="code-block">

0 commit comments

Comments
 (0)