CommandLineService

CommandLineService

Source:

Manages command line hooks. Callable using .tel.sh file or directly using index.js + command

Example

See 'hooks/examples/spammer.js' for a commandline hook definition

Members

(private, static) api

Source:
Properties:
Name Type Description
api TelegramService

Link to TelegramService

(private, static) initialized

Source:
Properties:
Name Type Description
initialized Boolean

If initialized

Methods

(static) execute(command, params) → {Promise}

Source:

Executes the command using the registered hook.
You can run .tel.sh help for a list of registered commands, then .tel.sh help COMMAND_NAME for a more specific view.

Parameters:
Name Type Description
command string

Command to be executed.

params object

command line passed params as defined in the hook.

Returns:
Type
Promise

(static) init(tapi) → {Promise}

Source:

Initialize command line hooks manager

Parameters:
Name Type Description
tapi TelegramService

Link to Telegram service

Returns:
Type
Promise