Opened by field remains blank for Request/RITM created via inbound email — Flow Designer script not
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
57m ago
Hi all,
I'm trying to fix an issue where the Opened by field comes up empty on Request/RITM records created via inbound email for a specific catalog item ("Request Help").
Setup:
- Catalog item "Request Help" uses a subflow named "Generic - Request Help: Fulfillment"
- Action 1: Get Catalog Variables from Request Help from Request Help — retrieves catalog variables including email_subject, requested_for, etc.
- Action 2: Update Request Record on table Request [sc_request], which sets several fields including Opened by via a scripted field value
Desired logic for Opened by (email submissions only):
- Match sender's email address to a sys_user record → use that user
- If no match found → use Requested For
- If Requested For is also empty → use a placeholder "Person not in Database" user
Current script in the "Opened by" field (Update Record action):
var emailSubject = fd_data["1_get_catalog_variables"].email_subject;
var requestedFor = fd_data["1_get_catalog_variables"].requested_for;
function getPersonNotInDatabase() {
var gr = new GlideRecord('sys_user');
gr.addQuery('first_name', 'Person not in');
gr.addQuery('last_name', 'Database');
gr.query();
if (gr.next()) {
return gr.sys_id.toString();
}
return null;
}
if (emailSubject) {
if (requestedFor) {
return requestedFor;
}
return getPersonNotInDatabase();
}
return getPersonNotInDatabase();
Issue:
Despite this script, Opened by is still blank on newly created Request/RITM records when tested via a real inbound test email (subject line matching the expected trigger condition). Requested For also shows blank on the resulting record in some tests.
What I've checked so far:
- Confirmed the inbound email is received and marked "Processed" in Inbound Email logs
- Confirmed the Request/RITM record IS being created
- Confirmed the flow is Published (not draft)
- Uncertain whether fd_data["1_get_catalog_variables"] is the correct reference key for the "Get Catalog Variables from Request Help from Request Help" action — the action's auto-generated internal name may differ from what I've hardcoded .
@Ankur Bawiskar - can u please help me here to fix this issue . Please help me to fix this .
0 REPLIES 0