(options: BaseListOptions)
| 288 | } |
| 289 | |
| 290 | export async function listModels(options: BaseListOptions): Promise<void> { |
| 291 | const format = parseFormat(options.format) |
| 292 | |
| 293 | await withHostAndSignalHandlers(options, { ephemeral: true }, async (host) => { |
| 294 | const models = await requestOpenRouterModels(host) |
| 295 | |
| 296 | if (format === "json") { |
| 297 | outputJson({ models }) |
| 298 | return |
| 299 | } |
| 300 | |
| 301 | outputModelsText(models) |
| 302 | }) |
| 303 | } |
| 304 | |
| 305 | export async function listSessions(options: BaseListOptions): Promise<void> { |
| 306 | const format = parseFormat(options.format) |
no test coverage detected