create_email_script
Generate dynamic ServiceNow email scripts for notifications with custom recipients, conditional subjects, and loop prevention. Produces deploy-ready payload.
Instructions
Generate a ServiceNow Email Script (sys_script_email) for dynamic notification logic.
Email Scripts are used when a notification needs:
Dynamic recipients (e.g. add manager as CC)
Conditional subject lines
Dynamic body content based on record state
Loop-prevention logic
Returns deploy-ready payload with best-practice template.
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": {
"name": "<name>"
},
"name": "create_email_script"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Email Script name | |
| description | No | ||
| logic | No | Core logic to embed (pseudo-code is fine) |