Skip to content

Commit 93c8fae

Browse files
authored
Merge pull request #13 from runcycles/claude/clarify-api-key-docs-L5wR1
Add API key creation instructions to README
2 parents 1081149 + f615397 commit 93c8fae

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

README.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,15 @@ def call_llm(prompt: str, tokens: int) -> str:
4646
result = call_llm("Hello", tokens=100)
4747
```
4848

49+
> **Need an API key?** API keys are created via the Cycles Admin Server (port 7979). See the [deployment guide](https://docs.runcycles.io/quickstart/deploying-the-full-cycles-stack#step-3-create-an-api-key) to create one, or run:
50+
> ```bash
51+
> curl -s -X POST http://localhost:7979/v1/admin/api-keys \
52+
> -H "Content-Type: application/json" \
53+
> -H "X-Admin-API-Key: admin-bootstrap-key" \
54+
> -d '{"tenant_id":"acme-corp","name":"dev-key","permissions":["reservations:create","reservations:commit","reservations:release","reservations:extend","reservations:list","balances:read","decide","events:create"]}' | jq -r '.key_secret'
55+
> ```
56+
> The key (e.g. `cyc_live_abc123...`) is shown only once — save it immediately. For key rotation and lifecycle details, see [API Key Management](https://docs.runcycles.io/how-to/api-key-management-in-cycles).
57+
4958
### Programmatic client
5059
5160
```python
@@ -106,6 +115,8 @@ config = CyclesConfig.from_env()
106115
# Reads: CYCLES_BASE_URL, CYCLES_API_KEY, CYCLES_TENANT, etc.
107116
```
108117
118+
> **Need an API key?** See the [deployment guide](https://docs.runcycles.io/quickstart/deploying-the-full-cycles-stack#step-3-create-an-api-key) or [API Key Management](https://docs.runcycles.io/how-to/api-key-management-in-cycles).
119+
109120
### All options
110121
111122
```python

0 commit comments

Comments
 (0)