How can I populate custom fields which we have added to requests, through maileater?
search cancel

How can I populate custom fields which we have added to requests, through maileater?

book

Article ID: 54326

calendar_today

Updated On:

Products

CA IT Asset Manager CA Software Asset Manager (CA SAM) ASSET PORTFOLIO MGMT- SERVER SUPPORT AUTOMATION- SERVER CA Service Desk Manager - Unified Self Service CA Service Desk Manager CA Service Management - Asset Portfolio Management CA Service Management - Service Desk Manager

Issue/Introduction

I have added some custom fields to the "cr" table, and I need to be able to populate them with information when a request is logged through the maileater interface (in this example, I've added a STRING(30) field called "zunit"). I've sent an e-mail to the correct maileater e-mail address, with the following contents:

Subject: request

%category=Email
%priority=4
%zunit=Support
%description=E-mail not working.

but the e-mail which is returned by maileater contains the following error:

AHD58021: Successfully Created Request 494.

AHD58041: Invalid Input (%zunit=Support). Input will be ignored.

How do I configure maileater so that the ticket is opened with the information that is needed?

Environment

CA Service Desk Manager 17.X

Resolution

The maileater process sends the body of the incoming e-mail to the Text API for processing. The behavior of the Text API is controlled by the file %NX_ROOT%\site\text_api.cfg. Each ticket type has its own entry in this file. Keywords are defined for each field that can or needs to contain a value when the ticket is opened.

Each keyword defined has a conversion method.
The same applies to fields that establish a relationship with other tables.
You just need to check if any of the existing ones apply to your field.
For simple field types there is not a conversion method. You just need to reference the field name and the type.

For lookup fields it is necessary to check which conversion method applies.

This information can be found in the Administration Guide,  "Using the Text API", you will find 'Conversion Methods'.

For example, for the Organization table the following method is defined:

Method Output Type
lookup_org STRING

So, in this case, search for the following block in text_api.cfg file:

#   
#########################################################################   
# KEYWORDS:   
#   
# Below define valid keywords that can be used. Use keywords to map   
# input value to name in .maj files. If the input value needs to be   
# converted, you can use an optional method to do the conversion.  

This is the start of the section which determines which fields in the "cr" table can be seen (and therefore updated) by the Text API. To add the custom field, add it after this section, so this section now looks like this:

REQUEST.TYPE=type.STRING
REQUEST.URGENCY=urgency.INTEGER.lookup_urgency
REQUEST.URGENCY_PERSID=urgency.INTEGER.lookup_urgency_by_persid
REQUEST.ZUNIT=zunit.STRING

Then recycle Service Desk Services so the change is recognized and add %zunit=<add the organization name here> to the message body.

Additional Information:

  • The same rule applies to field types such as String and numbers.