MCPcopy Create free account
hub / github.com/agentrpc/agentrpc / validateFunctionName

Function validateFunctionName

sdk-node/src/util.ts:47–53  ·  view source on GitHub ↗
(name: string)

Source from the content-addressed store, hash-verified

45};
46
47export const validateFunctionName = (name: string) => {
48 if (!ALLOWED_NAME_CHARACTERS.test(name)) {
49 throw new AgentRPCError(
50 `Function name must only contain letters and numbers. Got: ${name}`,
51 );
52 }
53};
54
55export const validatePropertyName = (name: string) => {
56 const ALLOWED_PROPERTY_NAME_CHARACTERS = /^[a-zA-Z0-9_]+$/;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected