Space Docs
API ReferenceBot Command

botCommand.register

Type: Mutation · Auth: Workspace-aware

Input

FieldTypeRequiredDefaultDescription
providerenum(telegram, whatsapp, discord, slack, microsoft_teams, ai_agent, email)Yes—Provider
commandNamestringYes—Command name
commandSchemaJsonobjectNo—Command schema json
handlerNamestringYes—Handler name
workspaceIdstringYes—ID of the associated workspace
channelEndpointIdstringNo—ID of the associated channel endpoint
enabledbooleanYestrueEnabled
visibilityModeunknownNo—Visibility mode

Example

{
  "provider": "telegram",
  "commandName": "example",
  "commandSchemaJson": null,
  "handlerName": "example",
  "workspaceId": "550e8400-e29b-41d4-a716-446655440000",
  "channelEndpointId": "550e8400-e29b-41d4-a716-446655440000",
  "enabled": true
}

On this page