fix(voice-call): add missing region/edge uiHints, schema patterns, docs

- Add twilio.region and twilio.edge uiHints to index.ts (was only in
  openclaw.plugin.json)
- Add pattern constraints to JSON schema to match Zod validation
- Allow digits in edge regex (^[a-z0-9-]+$) for future-proofing
- Mention region/edge in SKILL.md Twilio config line
This commit is contained in:
giumex 2026-02-28 14:51:55 +01:00
parent e5efc5bb87
commit 91d1065f52
4 changed files with 16 additions and 4 deletions

View File

@ -46,6 +46,16 @@ const voiceCallConfigSchema = {
"telnyx.publicKey": { label: "Telnyx Public Key", sensitive: true },
"twilio.accountSid": { label: "Twilio Account SID" },
"twilio.authToken": { label: "Twilio Auth Token", sensitive: true },
"twilio.region": {
label: "Twilio Region",
help: "Processing region: ie1 (Ireland) or au1 (Australia). Omit for US1 (default). Requires region-specific auth credentials.",
advanced: true,
},
"twilio.edge": {
label: "Twilio Edge Location",
help: "Edge location (e.g. dublin, sydney, ashburn). Auto-inferred from region if omitted.",
advanced: true,
},
"outbound.defaultMode": { label: "Default Call Mode" },
"outbound.notifyHangupDelaySec": {
label: "Notify Hangup Delay (sec)",

View File

@ -206,10 +206,12 @@
"type": "string"
},
"region": {
"type": "string"
"type": "string",
"pattern": "^[a-z0-9]+$"
},
"edge": {
"type": "string"
"type": "string",
"pattern": "^[a-z0-9-]+$"
}
}
},

View File

@ -78,7 +78,7 @@ export const TwilioConfigSchema = z
*/
edge: z
.string()
.regex(/^[a-z-]+$/)
.regex(/^[a-z0-9-]+$/)
.optional(),
})
.strict();

View File

@ -39,7 +39,7 @@ Notes:
- Requires the voice-call plugin to be enabled.
- Plugin config lives under `plugins.entries.voice-call.config`.
- Twilio config: `provider: "twilio"` + `twilio.accountSid/authToken` + `fromNumber`.
- Twilio config: `provider: "twilio"` + `twilio.accountSid/authToken` + `fromNumber`. Optional `twilio.region` (ie1, au1) and `twilio.edge` (dublin, sydney) for non-US regions.
- Telnyx config: `provider: "telnyx"` + `telnyx.apiKey/connectionId` + `fromNumber`.
- Plivo config: `provider: "plivo"` + `plivo.authId/authToken` + `fromNumber`.
- Dev fallback: `provider: "mock"` (no network).