send_message_to_user
Send a direct message to a user on the Moodle-based campus platform, with optional dry-run validation before actual delivery.
Instructions
Send an instant message to a user.
By default runs in dry_run mode. Set dry_run=False to actually send.
Args: user_id: Recipient user ID. message: Message text. dry_run: If True (default), validate without sending.
Returns: JSON with validated status and msgid if sent.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"user_id": "<user_id>",
"message": "<message>"
},
"name": "send_message_to_user"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| dry_run | No | ||
| message | Yes | ||
| user_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |