xai-org/x-algorithm · error · ConfigFailure
Endpoint '$endpoint' does not match $endpointRegex.
Error message
Endpoint '$endpoint' does not match $endpointRegex.
What it means
Endpoint identifiers must match endpointRegex, with one special case: the literal endpoint "ScribeClient" is exempt. validateEndpoint throws ConfigFailure for any other endpoint string that does not match the regex.
Source
Thrown at botmaker/src/scala/com/twitter/botmaker/runtime/config/ServiceConfigs.scala:89
if (fieldNameRegex.findFirstIn(fieldName).isEmpty) {
throw ConfigFailure(
s"Field name '$fieldName' does not match $fieldNameRegex."
)
}
}
def validateFuncName(funcName: String): Unit = {
if (funcNameRegex.findFirstIn(funcName).isEmpty) {
throw ConfigFailure(
s"Func name '$funcName' does not match $funcNameRegex."
)
}
}
def validateEndpoint(endpoint: String): Unit = {
if (endpoint != "ScribeClient"
&& endpointRegex.findFirstIn(endpoint).isEmpty) {
throw ConfigFailure(
s"Endpoint '$endpoint' does not match $endpointRegex."
)
}
}
def validateDataset(dataset: String): Unit = {
if (datasetRegex.findFirstIn(dataset).isEmpty) {
throw ConfigFailure(
s"Dataset '$dataset' does not match $datasetRegex."
)
}
}
def validateTypeName(typename: String): Unit = {
if (typeNameRegex.findFirstIn(typename).isEmpty) {
throw ConfigFailure(
s"TypeName '$typename' does not match $typeNameRegex."
)View on GitHub (pinned to 24c60942c5)
Solutions
- Use a plain identifier matching endpointRegex instead of a URL/path
- For scribe ingestion use exactly "ScribeClient" (case-sensitive)
- Test endpoint names against endpointRegex in config unit tests
Example fix
// before
endpoint("/v1/content-scan")
// after
endpoint("ContentScan")
// or, for scribe consumption:
endpoint("ScribeClient") Defensive patterns
Strategy: type-guard
Validate before calling
ENDPOINT_RE = re.compile(r'^[A-Za-z][A-Za-z0-9_]*$') # mirror endpointRegex def validEndpoint(ep): return ep == "ScribeClient" or bool(ENDPOINT_RE.match(ep))
Type guard
def isValidEndpoint(ep: str) -> bool:
return ep == "ScribeClient" or bool(ENDPOINT_RE.match(ep)) Prevention
- Never pass URL paths as endpoint identifiers
- Remember the ScribeClient exemption is case-sensitive
When it happens
Trigger: Registering an endpoint whose name fails endpointRegex and is not exactly "ScribeClient" — e.g. URLs, endpoints with slashes or colons, lowercase-with-dashes names.
Common situations: Confusing HTTP endpoint paths ('/api/v1/scan') with BotMaker endpoint identifiers; using scribe-style names without the ScribeClient exemption; mixed-case typos of ScribeClient like 'scribeClient' (case-sensitive — not exempt).
Related errors
- Event type '$eventType' does not match $eventTypeRegex.
- Field name '$fieldName' does not match $fieldNameRegex.
- Func name '$funcName' does not match $funcNameRegex.
- Dataset '$dataset' does not match $datasetRegex.
- TypeName '$typename' does not match $typeNameRegex.
AI-assisted analysis of xai-org/x-algorithm@24c60942c5 (2026-08-28).
Data as JSON: /api/errors/fe8cd19fd71f9030.
Report an issue: GitHub.