Skip to content

Commit 8e1a611

Browse files
committed
docs(README): 📝 Update usage examples for OpenAPI filter command
- Modify CLI usage example to reflect correct paths - Enhance Docker usage example with updated paths
1 parent 66e8037 commit 8e1a611

1 file changed

Lines changed: 24 additions & 1 deletion

File tree

README.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,30 @@ A CLI tool to work with OpenAPI specifications, including generation, validation
77
Below is a quick example using the Azure OpenAI Service:
88

99
```bash
10-
npx @ai-foundry/openapi-tools filter --input openapi.yaml --output filtered.yaml --select-paths "/v1/chat/completions,/v1/models"
10+
npx @ai-foundry/openapi-tools filter --input openapi.yaml --output filtered.yaml --select-paths "/pet/{petId},/pet/findByStatus"
11+
```
12+
13+
### Docker Usage Example
14+
15+
You can also use the tool via Docker:
16+
17+
```bash
18+
docker run --rm -v $(pwd)/local-schemas:/app/schemas adrianhdezm/openapi-tools filter --input ./schemas/openapi.yaml --output ./schemas/filtered.yaml --select-paths "/pet/{petId},/pet/findByStatus"
19+
```
20+
21+
## Command Reference
22+
23+
```
24+
Usage: openapi-tools filter [options]
25+
26+
Filter OpenAPI spec by comma-separated list of path names
27+
28+
Options:
29+
--input <input> Input OpenAPI YAML file
30+
--output <output> Output filtered YAML file
31+
--select-paths <paths> Comma-separated list of path names, e.g.,
32+
"/v1/chat/completions,/v1/models"
33+
-h, --help display help for command
1134
```
1235

1336
## License

0 commit comments

Comments
 (0)