Send Messages v2
post
/v2/message
Sends an EnterpriseOne message (PPAT) to external email systems or the EnterpriseOne Work Center email system.
Request
Supported Media Types
- application/json
Header Parameters
-
jde-AIS-Auth: string
Token
-
jde-AIS-Auth-Device: string
Device Name
-
jde-AIS-MonitorOnStart: boolean
Monitor on Start
-
jde-AIS-MonitorRequest: string
Monitor RequestAllowed Values:
[ "monitorRequest", "monitorRequestIO" ]
The input to the message service that sends JD Edwards messages.
Root Schema : MessageRequest
Type:
object
The input to the message service that sends JD Edwards messages.
Show Source
-
deviceName:
string
An identifier for the device making the service call. If not provided, the requesting IP address is used.
-
environment:
string
Specify the environment to use for login. If not specified, the default environment configured for the AIS Server will be used.
-
jasserver:
string
The HTML (JAS) Server to use for login. If not specified, the default HTML Server configured for the AIS Server will be used.
-
messageDetails(required):
object SendMessageDetails
Container for the details of the message.
-
password:
string
The JD Edwards EnterpriseOne password, which is required if other authentication methods are not being used.
-
psToken:
string
Used for logging in with psToken. Primarily used by the HTML Server to establish a session with the AIS Server.
-
role:
string
The role to use for login. If not specified, the default role configured for the AIS Server will be used.
-
token:
string
The AIS token, which is required if other authentication methods are not being used.
-
username:
string
JD Edwards EnterpriseOne username, which is required if other authentication methods are not being used.
Nested Schema : SendMessageDetails
Type:
object
Container for the details of the message.
Show Source
-
send_message_ext(required):
object SendMessageExtended
Detail of the message to send including recipients and the content of the message.
Nested Schema : SendMessageExtended
Type:
object
Detail of the message to send including recipients and the content of the message.
Show Source
-
attachments:
object Attachments
-
bcc:
object Receiver
Details of entity to recieve the message.
-
cc:
object Receiver
Details of entity to recieve the message.
-
mailbox:
string
The mailbox the messge will be recieved in, if recieved in Work Center. The list of valid values is in UDC 02/MB. If no value is passed the message will be delivered to the default mailbox.
-
message_text(required):
string
The body of the message.
-
messageBodyAsRichText:
string
-
messageBodyAsRichTextRT:
string
-
messageHeading:
string
Bold text inserted in the message before the message_text.
-
moreActions:
object MoreActions
Additional applicaiton links to append to the message.
-
msgAsRichText:
boolean
-
services:
object Services
-
shortcut:
object Shortcut
Use this area to define an EnterpriseOne application shortcut to be included in the message.
-
subject(required):
string
The subject of the message.
-
template:
object Template
Container for the details of a text substitution message to be included in the main message.
-
to(required):
object Receiver
Details of entity to recieve the message.
Nested Schema : Attachments
Type:
Show Source
object
-
attachment:
array attachment
-
includeBinaryInEmail:
boolean
A value of true (default) indicates the attachments will be sent as files included in the message. A value of false indicates a link to report attachments will be included in the message.
Nested Schema : Receiver
Type:
object
Details of entity to recieve the message.
Show Source
-
recipient(required):
array recipient
Container for the details of the recipients. Currently, only one recipient is supported.
Nested Schema : MoreActions
Type:
object
Additional applicaiton links to append to the message.
Show Source
-
shortcut:
array shortcut
List of additional application links.
Nested Schema : Services
Type:
Show Source
object
-
service:
array service
A list of service links to include in the message.
Nested Schema : Shortcut
Type:
object
Use this area to define an EnterpriseOne application shortcut to be included in the message.
Show Source
-
application(required):
string
The application to link to, P01012 for example.
-
form_name(required):
string
The form in that applicaiton to link to, W01012A for example.
-
formInterconnect:
object FormInterconnect
Used to pass form interconnect values to a shortcut included in a message.
-
linkText:
string
The text for the link that launches the application shortcut (if not provided the form title will default).
-
postText:
string
Text appended to the application link.
-
preText:
string
Text prepended to the application link.
-
serviceParameter:
array serviceParameter
Additional parameters to append to the shortcut link that launches the application.
-
taskTracking:
object TaskTracking
-
version:
string
The verion of the application to link to, ZJDE0001 for example.
Nested Schema : Template
Type:
object
Container for the details of a text substitution message to be included in the main message.
Show Source
-
dictionary_item(required):
string
The data dictionary alias of the text substitution message.
-
parameter(required):
array parameter
A list of parameters to set values for the text substitution elements.
Nested Schema : Attachment
Type:
Show Source
object
-
gtKey:
string
For media object attachments the bar delimited key.
-
gtStructureName:
string
For media object attachments the GT structure of the media object. Populating this value indicates you want Media Object type attachments.
-
jobNumber:
string
For Report attachments the job number.
-
language:
string
Allowed Values:
[ "AR-Arabic", "CS-Czech", "DA-Danish", "DE-German", "EL-Greek", "EN-English", "ES-Spanish", "FI-Finnish", "FR-French", "HU-Hungarian", "IT-Italian", "JA-Japanese", "KO-Korean", "NL-Dutch", "NO-Norwegian", "PL-Polish", "PT-Portuguese", "RU-Russian", "SV-Swedish", "TR-Turkish", "ZH-Chinese" ]
For BI report attachments the two letter language code for the report to attach, 'EN' is the default. -
outputType:
string
Allowed Values:
[ "PDF", "ETEXT", "HTML", "EXCEL", "XML", "RTF", "PPT" ]
For report attachments the file type to attach. -
reportName:
string
For report attachments the report name, R01234 for example.
-
sequence:
integer(int32)
For media object attachments the sequence number of the single media object. Send sequence of 0 (zero) to attach all for this key.
-
server:
string
For Report attachments the execution server for the job.
-
type:
string
Allowed Values:
[ "ube", "mo" ]
Type of attachment, report (ube) is the default, or media object (mo).
Nested Schema : recipient
Type:
array
Container for the details of the recipients. Currently, only one recipient is supported.
Show Source
-
Array of:
object Recipient
A recipient of the message (in the to, cc, or bcc field).
Nested Schema : Recipient
Type:
object
A recipient of the message (in the to, cc, or bcc field).
Show Source
-
address_number:
string
An EnterpriseOne address number. This can be used directly as the recipient (ADDRESS_NUMBER) or it can be used in conjunction with contact number (CONTACT) or in conjunction with structure type (DISTRIBUTION)
-
contact_number:
string
The line id of the Who's Who contact related to the address number given. Used in CONTACT type recipients.
-
email_address:
string
A fully qualified e-mail address. Used for EMAIL type recipients.
-
recipient_type(required):
string
Allowed Values:
[ "CONTACT", "ADDRESS_NUMBER", "DISTRIBUTION", "EMAIL" ]
The type of the receipient. This field determines which of the other input fields will be used. -
structure_type:
string
The structure type (P0150) associated with the given address number as the parent of the structure. Used in DISTRIBUTION type recipients.
Nested Schema : shortcut
Type:
array
List of additional application links.
Show Source
-
Array of:
object Shortcut
Use this area to define an EnterpriseOne application shortcut to be included in the message.
Nested Schema : Service
Type:
Show Source
object
-
isE1:
boolean
Indicates if the service is an EnterpriseOne service.
-
linkText:
string
The text for the link to the url.
-
postText:
string
Text to apear after the service link in the message.
-
preText:
string
Text to apear before the service link in the message.
-
serviceParameter:
array serviceParameter
A list parameters to include in the service link in the message.
-
taskTracking:
object TaskTracking
-
udoName:
string
-
url:
string
The service URL.
Nested Schema : serviceParameter
Type:
array
A list parameters to include in the service link in the message.
Show Source
-
Array of:
object ServiceParameter
Use this area to define additional parameters to the application shortcut
Nested Schema : TaskTracking
Type:
Show Source
object
-
dateRuleAmount:
integer(int32)
-
dateRuleOption:
string
-
dueDateOverrideAllowed:
boolean
-
dueDateRule:
string
-
dueDateVariable:
string
-
dueTime:
string
-
dueTimeZone:
string
-
includeLinkOption:
string
-
linkText:
string
-
taskDescription:
string
-
trackBySubscriber:
boolean
-
trackingStatuses:
array trackingStatuses
-
trackTask:
boolean
Nested Schema : ServiceParameter
Type:
object
Use this area to define additional parameters to the application shortcut
Show Source
-
encryptValue:
boolean
A value of true indicates the data in the value field should be encrypted.
-
key(required):
string
The key for the parameter.
-
value(required):
string
The value of the parameter.
Nested Schema : FormInterconnect
Type:
object
Used to pass form interconnect values to a shortcut included in a message.
Show Source
-
data_structure_template(required):
string
The form ID whose data structure you will map to, W01012A for example.
-
formInputs(required):
array formInputs
List of data structure mappings for form interconnects.
Nested Schema : serviceParameter
Type:
array
Additional parameters to append to the shortcut link that launches the application.
Show Source
-
Array of:
object ServiceParameter
Use this area to define additional parameters to the application shortcut
Nested Schema : formInputs
Type:
array
List of data structure mappings for form interconnects.
Show Source
-
Array of:
object FormInput
Used if the message contains a shortcut link, including mappings here will allow you to pass values to the application that is launched with the shortcut.
Nested Schema : FormInput
Type:
object
Used if the message contains a shortcut link, including mappings here will allow you to pass values to the application that is launched with the shortcut.
Show Source
-
id(required):
string
The data structure member id.
-
value(required):
string
The value to pass in.
Nested Schema : parameter
Type:
array
A list of parameters to set values for the text substitution elements.
Show Source
-
Array of:
object Parameter
Details of the parameter to substitute in a text substitution message.
Nested Schema : Parameter
Type:
object
Details of the parameter to substitute in a text substitution message.
Show Source
-
index(required):
integer(int32)
The index of the text substitution element. The index is zero based: &1 is index 0, &2 is index 1.
-
value(required):
string
The value to substitute for the text substitution element.
Response
Supported Media Types
- application/json
200 Response
Successful Execution
400 Response
Bad Request - Invalid JSON Input
403 Response
Authorization Failure
415 Response
Invalid Content-Type Header - Must use application/json
444 Response
Invalid Token
Root Schema : ServiceErrorResponse
Type:
object
Error Response
Show Source
-
errorText:
string
-
exception:
string
The class of the exception if an exception was thrown.
-
exceptionId:
string
ExceptionId, only if an exception record was written to the F980060
-
message:
string
Details about the error.
-
status:
string
Allowed Values:
[ "ERROR", "WARNING" ]
Status determined by exception handling -
timeStamp:
string
The timestamp indicating the time the error message was returned.
-
type:
string
Optional type of error
-
userDefinedErrorText:
string
Optional error text added to an orchestration step.
500 Response
Server Failed to Process Request
Root Schema : ServiceErrorResponse
Type:
object
Error Response
Show Source
-
errorText:
string
-
exception:
string
The class of the exception if an exception was thrown.
-
exceptionId:
string
ExceptionId, only if an exception record was written to the F980060
-
message:
string
Details about the error.
-
status:
string
Allowed Values:
[ "ERROR", "WARNING" ]
Status determined by exception handling -
timeStamp:
string
The timestamp indicating the time the error message was returned.
-
type:
string
Optional type of error
-
userDefinedErrorText:
string
Optional error text added to an orchestration step.
Examples
Example Request
The following shows an example of a message service request to send a message with all three recipients (to, cc, bcc). The 'to' is a distribution list, structure EML, parent 6001. The 'cc' is a contact, for address book 6001, contact 1. The 'bcc' is an email, with an SMPT email address. It has a subject and body text, it includes a text substitution message (template) as well as a shortcut link to a E1 application passing form interconnect values.
curl -i -X POST -H "Content-Type:application/json" http://ais_server_url/jderest/v2/message/ -d { "token": "044cM+78v6mYfVHcv8oT1tYRHoBtkPjNLQLdq1p13mh41c=MDE5MDEzMjgyOTAwNDcxMDE4NDk4OTk5NjEwLjEzOS4xMTUuNTUxNDg1Mjc4NDYwNzA5", "messageDetails": { "send_message_ext": { "to": { "recipient": [ { "recipient_type": "DISTRIBUTION", "address_number": 6001, "structure_type": "EML" } ] }, "cc": { "recipient": [ { "recipient_type": "CONTACT", "address_number": 6001, "contact_number": 1 } ] }, "bcc": { "recipient": [ { "recipient_type": "EMAIL", "email_address": "test_email@otestco.com" } ] }, "mailbox": "", "subject": "Test JSON Input SoapUI", "message_text": "Test SoapUI Json Input Body", "template": { "dictionary_item": "LM0820", "parameter": [ { "index": 0, "value": "Sub One" }, { "index": 1, "value": "Sub Two" } ] }, "shortcut": { "application": "P01012", "form_name": "W01012A", "version": "ZJDE0001", "formInterconnect": { "data_structure_template": "W01012A", "formInputs": [ { "id": "12", "value": "4803" }, { "id": "13", "value": "E" }, { "id": "14", "value": "1.00" } ] } } } } }
Example Response
The following example shows the contents of the response body.
{"success": true}