Creating a File Carrier

Top  Previous  Next

This type of carrier tells PageGate to write a file to a specified directory when a message needs to be sent. This is often used in conjunction with PageGate's two-way messaging system but can be implemented any time you need messages written out as a file to a specified location.

 

It is also important to note that you must apply a Text template to any File protocol carrier that you create.

 

This protocol also allows you to write files for the GetASCII API to process, which allows you to take input from other APIs, whether they're PageGate's or a web API, and process it in to a readable message.

 

1)Right click Carriers.

CarriersContext

 

2)Select Add.

3)Select the File protocol.

FILE1

 

4)Enter a name in the Carrier field.

5)In the File Path field, enter the location to which you want these files output. This can be set to a local path (example: c:\PageGateData\ASCII\) or it can be set to a network path (\\servername\share\). If this carrier is referencing a network path, the PageGate Connector services will need a service account to grant them access to the necessary network resource. Click here for more information.

 

6)Select the extension you want the files to have.

7)Set the Max Chars field to the maximum number of characters you want output in a single file. The maximum value of this field is 6000.

Note: The Carrier Max Chars field determines the number of characters that can be received in a single message. If the recipient Max Chars value is set higher than the carrier Max Chars value, PageGate will break up long messages based on the character limitation in the carrier. For example, if you have the carrier configured for 160 Max Chars and you set the recipient Max Chars value to 3000, then send a 400 character message to this recipient, PageGate will break up the 400 character count message in to two 160 character messages and one 80 character message. When the device receives the message, it will be prefixed with part 1/3, 2/3, 3/3 to indicate the multi-part nature of the message delivered.

 

FILE2

 

8)Click Apply.

 

Now that we have the carrier created, go in to its Template sub-section.

FILE3

In the Text section of the template, you'll want to configure a string of Macros to tell PageGate what should be output. For example, if we used the following:
 
%Recipient%

%Sender%

%Message%

 

That tells PageGate to output the recipient's name followed by a carriage return, line feed then the recorded sender value followed by a carriage return, line feed then the body of the message in the file written.

 

As another example, if we used the following:

%Message% has failed to %Recipient% on %Date% at %Time%

 

That tells PageGate to output the body of the message has failed to the recipient in question on the date of its occurrence at the time of its occurrence.

 

This allows you to implement the File protocol in any number of ways, from feeding information back in to PageGate's GetASCII API and Filter Pack to outputting a copy of any message as a file for safe keeping or secondary processing by other applications.

 

Also, bear in mind that while these are examples of what can be done with this type of carrier, it's important to note the base action in play:

You're having PageGate output a text file to a specified location.