Commit edaec5e
committed
feat: API - Auto-generating the CLI from the real API
Usage:
```
uv run tangle api
Usage: tangle api COMMAND
Call the Tangle API server.
Commands:
admin
artifacts
component-libraries
component-library-pins
components
executions
pipeline-runs
published-components
secrets
users
```
TANGLE_API_URL="http://127.0.0.1:8000" TANGLE_API_TOKEN="XXX" uv run tangle api pipeline-runs set-annotation 0123 --key key1 --value value1
```
Debug:
```
uv run tangle api pipeline-runs set-annotation 12 --key k1 --value v1 --debug
PUT http://127.0.0.1:8000/api/pipeline_runs/12/annotations/k1?value=v1
```
Complex parameters can be read from string or JSON/YAML files.
Pydantic parameters are validated against the model classes.1 parent bfb093b commit edaec5e
4 files changed
Lines changed: 780 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
0 commit comments