Prompt Details
Model
Chat - GPT-4o (gpt-4o)
Token size
48 ($0.00240 / call)
Example input
[Write a JavaScript script for a ServiceNow Email Inbound Action that processes incoming emails based on specific conditions. Use email object properties like email. Subject, email. Body, email. From, etc. to determine actions in ServiceNow.]: Write a ServiceNow Email Inbound Action script in JavaScript that automatically creates an Incident when an email with the subject containing "Urgent Issue" is received.
Example output
if (email.subject.indexOf("Urgent Issue") > -1) {
var incident = new GlideRecord("incident");
incident.initialize();
incident.short_description = email.subject;
incident.description = email.body_text;
incident.caller_id.setDisplayValue(email.from);
incident.urgency = 1;
incident.insert();
}
By purchasing this prompt, you agree to our terms of service
GPT-4O
This package includes four ready-to-use JavaScript scripts:
Incident Creation – Automatically creates an incident when an email with "Urgent Issue" is received.
Incident Update – Updates an existing incident when an email contains an incident number.
Task Assignment – Assigns tasks to the IT Support group when specified in the email.
Change Request Creation – Creates a change request when an email with "New Change Request" is received.
...more
Added over 1 month ago
