sdk operations
列出生成器从当前规范中读取的操作:包括每个操作的方法、路径和操作 ID。这些内容会成为 SDK 的方法,因此这是检查规范变更是否按预期生效的最快方式。
bash
octri sdk operations [--grep <text>]标志
--grep <text>string仅显示方法、路径或摘要中包含此内容的操作,不区分大小写。
示例
查找客户相关操作
bash
octri sdk operations --grep customerOutput
✔ Parsing current spec
Operations (6/23)
METHOD PATH OPERATIONID
────── ───────────────────────────────────── ─────────────────────────
GET /customers listCustomers
POST /customers createCustomer
DELETE /customers/{customerId} deleteCustomer
GET /customers/{customerId} getCustomer
PATCH /customers/{customerId} updateCustomer
GET /customers/{customerId}/subscriptions listCustomerSubscriptions相关内容
octri sdk preview:无需消耗构建额度即可生成一种语言,并查看文件。octri specs push:上传 OpenAPI 规范,并跟踪其解析、页面生成和搜索索引构建过程。