unraidclaw 0.1.11 → 0.1.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -0
- package/openclaw.plugin.json +36 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -71,6 +71,24 @@ With multi-server config, every tool accepts an optional `server` parameter (e.g
|
|
|
71
71
|
|
|
72
72
|
Set `tlsSkipVerify: true` when using UnraidClaw's auto-generated self-signed certificate.
|
|
73
73
|
|
|
74
|
+
### Keeping the API key out of the config file
|
|
75
|
+
|
|
76
|
+
You don't have to hard-code the key in `openclaw.json`. Two options:
|
|
77
|
+
|
|
78
|
+
**Environment variable** — OpenClaw expands `${VAR}` references at config-load time:
|
|
79
|
+
|
|
80
|
+
```json
|
|
81
|
+
"apiKey": "${UNRAID_API_KEY}"
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
**Provider-backed secret (`SecretRef`)** — point `apiKey` at one of your configured secret providers; OpenClaw resolves it before the plugin loads, so the plugin only ever sees the resolved string:
|
|
85
|
+
|
|
86
|
+
```json
|
|
87
|
+
"apiKey": { "source": "file", "provider": "default", "id": "/unraidclaw_key" }
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
`source` is one of `file`, `env`, or `exec`; `provider` names a provider from your `secrets.providers` config; `id` is the lookup key. Both forms also work per-server on `servers[].apiKey`. (Requires unraidclaw 0.1.12+.)
|
|
91
|
+
|
|
74
92
|
## Usage
|
|
75
93
|
|
|
76
94
|
Once installed and configured, just ask your agent:
|
package/openclaw.plugin.json
CHANGED
|
@@ -49,6 +49,14 @@
|
|
|
49
49
|
"unraid_vm_stop"
|
|
50
50
|
]
|
|
51
51
|
},
|
|
52
|
+
"configContracts": {
|
|
53
|
+
"secretInputs": {
|
|
54
|
+
"paths": [
|
|
55
|
+
{ "path": "apiKey", "expected": "string" },
|
|
56
|
+
{ "path": "servers.*.apiKey", "expected": "string" }
|
|
57
|
+
]
|
|
58
|
+
}
|
|
59
|
+
},
|
|
52
60
|
"configSchema": {
|
|
53
61
|
"type": "object",
|
|
54
62
|
"additionalProperties": false,
|
|
@@ -58,8 +66,20 @@
|
|
|
58
66
|
"description": "URL of the UnraidClaw server (single-server mode)"
|
|
59
67
|
},
|
|
60
68
|
"apiKey": {
|
|
61
|
-
"
|
|
62
|
-
"
|
|
69
|
+
"description": "API key for authenticating with UnraidClaw (single-server mode). A plaintext string, or an OpenClaw SecretRef object resolved before the plugin loads.",
|
|
70
|
+
"anyOf": [
|
|
71
|
+
{ "type": "string" },
|
|
72
|
+
{
|
|
73
|
+
"type": "object",
|
|
74
|
+
"required": ["source", "provider", "id"],
|
|
75
|
+
"properties": {
|
|
76
|
+
"source": { "type": "string", "enum": ["env", "file", "exec"] },
|
|
77
|
+
"provider": { "type": "string" },
|
|
78
|
+
"id": { "type": "string" }
|
|
79
|
+
},
|
|
80
|
+
"additionalProperties": false
|
|
81
|
+
}
|
|
82
|
+
]
|
|
63
83
|
},
|
|
64
84
|
"tlsSkipVerify": {
|
|
65
85
|
"type": "boolean",
|
|
@@ -81,8 +101,20 @@
|
|
|
81
101
|
"description": "URL of the UnraidClaw server"
|
|
82
102
|
},
|
|
83
103
|
"apiKey": {
|
|
84
|
-
"
|
|
85
|
-
"
|
|
104
|
+
"description": "API key for authenticating with this server. A plaintext string, or an OpenClaw SecretRef object resolved before the plugin loads.",
|
|
105
|
+
"anyOf": [
|
|
106
|
+
{ "type": "string" },
|
|
107
|
+
{
|
|
108
|
+
"type": "object",
|
|
109
|
+
"required": ["source", "provider", "id"],
|
|
110
|
+
"properties": {
|
|
111
|
+
"source": { "type": "string", "enum": ["env", "file", "exec"] },
|
|
112
|
+
"provider": { "type": "string" },
|
|
113
|
+
"id": { "type": "string" }
|
|
114
|
+
},
|
|
115
|
+
"additionalProperties": false
|
|
116
|
+
}
|
|
117
|
+
]
|
|
86
118
|
},
|
|
87
119
|
"tlsSkipVerify": {
|
|
88
120
|
"type": "boolean",
|