slash_commands
Class info¶
Classes¶
| Name | Children | Inherits |
|---|---|---|
| AvailableCommand aclientp.schema.slash_commands Information about a command. |
||
| AvailableCommandInput aclientp.schema.slash_commands A container for the input specification for a command. |
||
| CommandInputHint aclientp.schema.slash_commands All text that was typed after the command name is provided as input. |
🛈 DocStrings¶
Slash command schema definitions.
AvailableCommand
¶
Bases: AnnotatedObject
Information about a command.
Source code in src/aclientp/schema/slash_commands.py
description
instance-attribute
¶
Human-readable description of what the command does.
input
class-attribute
instance-attribute
¶
input: AvailableCommandInput | None = None
Input for the command if required.
create
classmethod
¶
Create a new Command.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
name
|
str
|
Name of the command. |
required |
description
|
str
|
Description of the command. |
required |
input_hint
|
str | None
|
Hint for the input. |
None
|
Returns:
| Type | Description |
|---|---|
Self
|
A new available command. |
Source code in src/aclientp/schema/slash_commands.py
AvailableCommandInput
¶
Bases: RootModel[CommandInputHint]
A container for the input specification for a command.
Source code in src/aclientp/schema/slash_commands.py
CommandInputHint
¶
Bases: AnnotatedObject
All text that was typed after the command name is provided as input.