AS2 - Send message

Declaration

<AMAS2 ACTIVITY="send_message" AS2MESSAGE="text" URL="text" AS2RECEIPT="text" AUTHENTICATION="text (options)" USERNAME="text" PASSWORD="text (encrypted)" CERTIFICATE="test" CERTIFICATEPASSPHRASE="text (encrypted)" IGNOREINVALIDCERTIFICATE="YES/NO" USERAGENT="text" TIMEOUT="number" MEASURE="text (options) " PROXYTYPE="text (options)" PROXYSERVER="text" PROXYPORT="number" PROXYUSERNAME="text" PROXYPASSWORD="text (encrypted)" />

Related Topics    

Description

Sends an AS2 message created by the 'AS2 - Create message' activity.

Practical Usage

Designed to allow business transactions to move securely over the Internet.

Parameters

General

Property Type Required Default Markup Description
AS2 message file Text Yes (Empty) DATAFILE="C:\temp\filename.as2m" The location of the message (.as2m) file to be sent. All AS2 messages must derive from a specific file. This file contains extra fields such as From, To, and Data File. The full path and file name can be entered manually in the provided field or you can click the Folder icon to navigate to the file.
NOTE: Use AS2 - Create message step to create an AS2 message file.
Server URL Text Yes (Empty) SERVER="server.url.com" The Server URL in which to send the message from.
AS2 receipt file Text Yes (Empty) AS2FROM="Clark Kent" The file in which to save the asynchronous receipt to.
Overwrite existing file Yes/No No Yes OVERWRITEFILE="No" If selected (default), any receipt file with an identical name that already exists will be overwritten with the new receipt file. If disabled, no overwrites will occur, however, Automate will throw an error as a result.   

Credentials

Property Type Required Default Markup Description
Authentication type Text (options) No (Empty)
  • AUTHENTICATION="none"
  • AUTHENTICATION="basic"
  • AUTHENTICATION="digest"
  • AUTHENTICATION="NTLM"
The authentication type to use. The available options are:
  • None (default) - No authentication is required.
  • Basic - Basic authentication will be used.
  • Digest - Digest authentication will be used.
  • NTLM - NTLM authentication will be used.
Username Text No (Empty) USERNAME="user" The username used to authenticate. This parameter is ignored if None is selected from the Authentication Type parameter.
Password Text No (Empty) PASSWORD="encrypted text" The password used to authenticate. This parameter is ignored if None is selected from the Authentication Type parameter.
Certificate file Text No (Empty) CERTIFICATE="C:\temp\cert_file.cer" The certificate file to authenticate the AS2 message being sent.
Passphrase Text No (Empty) CERTIFICATEPASSPHRASE="encrypted" The passphrase associated to the certificate file.
Ignore invalid certificates Yes/No No No IGNOREINVALIDCERTIFICATE="YES" If selected, specifies that any invalid certificates found will automatically be ignored.

Advanced

Property Type Required Default Markup Description
User agent Text No Automate USERAGENT="Automate1" The user agent used to send the AS2 message.
Timeout Number No 100 TIMEOUT="50000" Along with the Measure parameter below, specifies the total amount of time that this activity should be allowed to complete before a time out error occurs.
Measure (unlabeled) Text (options) No Seconds
  • MEASURE="milliseconds"
  • MEASURE="seconds"
  • MEASURE="minutes"
  • MEASURE="hours"
The measure associated to the value entered under the Timeout parameter. The available options are:
  • Milliseconds - The value is measured in milliseconds.
  • Seconds (default) - The value is measured in seconds.
  • Minutes - The value is measured in minutes.
  • Hours - The value is measured in hours.
Proxy type Text (options) No System default
  • PROXYTYPE="default"
  • PROXYTYPE="none"
  • PROXYTYPE="socks4"
  • PROXYTYPE="socks4a"
  • PROXYTYPE="socks5"
  • PROXYTYPE="HTTP"
The type of proxy server to connect through (if required). The available options are:
  • System default (default) - Access always passes through a default proxy server.
  • None - No proxy server is required.
  • Socks 4 - Communication is through Socks 4 proxy server.
  • Socks 4A - Communication is through Socks 4A proxy server.
  • Socks 5 - Communication is through Socks 5 proxy server.
  • HTTP - Communication is through an HTTP proxy server.
Proxy server Text No (Empty) PROXYSERVER="server.domain.com The host name (server.domain.com) or IP address (xxx.xxx.xxx.xxx) of the proxy server. This parameter is active only if the Proxy type parameter is set to HTTP.
Proxy port Number No 808 PROXYPORT="8080" The port number that is used by the proxy server for client connections. The default value is 808.
Proxy username Text No (Empty) PROXYUSERNAME="theUsername" The username to authenticate with the proxy server. This parameter is active only if the Proxy type parameter is set to SOCKS5 or HTTP.
Proxy password Text No (Empty) PROXYPASSWORD="[encrypted]" The password to authenticate with the proxy server. This parameter is active only if the Proxy type parameter is set to SOCKS5 or HTTP.

Description

Error Causes

On Error

Example

NOTE:
  • The sample AML code below can be copied and pasted directly into the Steps Panel of the Task Builder.
  • Parameters containing user credentials, files, file paths, and/or other information specific to the task must be customized before the sample code can run successfully.

Description

This sample task sends an AS2 message to a server and then saves an AS2 receipt file.

Copy
<AMAS2 ACTIVITY="send_message" AS2MESSAGE="C:\temp\SendMessage.as2m" URL="http://localhost:8080/as2handler" AS2RECEIPT="C:\temp\receipt.as2r" TIMEOUT="200" MEASURE="seconds" />