AUTOMATED PRODUCT DOWNLOADS (PAYLOADS)

The SendSafe system can automatically create digital packages and manage the product download process. This is a powerful product fulfillment system that is built in and ready to go.

SendSafe includes built-in support to retieve and/or generate DRM keys for products.

SendSafe manages download security making sure that legitimate customers get their products and thieves do not. SendSafe supports either ftp or http product downloads. 

The Payload Process:

These are the steps that the SendSafe robot takes in handling digital payloads:

  1. Check Credit Card authorization (does not generate payload if authorization fails). Payload will always be generated if automated credit card authorization is not enabled.
  2. Collect all products payloads for an order.
  3. Zip all the products into a single file.
  4. Add password protection to the zip file (optional)
  5. Create a secure directory under the base download directory
  6. Move the payload to the secure directory
  7. Modify the acknowledgement e-mail to include a link to the download directory and any needed passwords.

Requirements:

  1. SendSafe must have direct file share access to the web server

DRM:

  1. All items sold using DRM must be flagged with the productType = $DRM$
  2. All items sold using DRM must be demultiplexed so there is one item per lineitem in the order.
  3. All DRM items must include a digital payload (setup defined below)

Setting up Digital Payloads:

  1. Select and configure a download base directory. This where SendSafe will build downloads for access by customers.
    1. Create a directory on the web server's hard disk under which the SendSafe robot will build temporary download sub directories.
    2. Setup this location to be served by either the http of ftp server.
    3. Set the physical hard disk location into SendSafe by setting the keyword: PAYLOAD DOWNLOAD BASE DIR.
    4. Set into SendSafe the base URL for the virtual download directory being served (http or ftp) by setting the keyword: PAYLOAD BASE URL. This base directory will be part of the URL e-mailed by SendSafe to customers for downloading. The Zip compression function will fail if the directory path contains spaces or other non-alphanumeric characters. Example of how the config value is used: ftp://<PAYLOAD BASE URL>/subdirectory/payload.zip
  2. Add Payload location or source information into the database for each item (that is downloadable - leave empty if there is no payload for a specific item).
  3. Set up your payload source directory. This the location from which the Robot will pickup "product files" to be added to the customer's download.
  4. Enable Payloads in the storefront's configuration file.
  5. Configure the TTL (the time that the payload will be available before it is removed from the server).
  6. Select to enable or disable passwords on zipped payload files. The password is the automatically created password assiged to a user account.
  7. Set payload directory encoding encoding length (obfusaction). The default value is 40 characters.
Example Confir File setup
PAYLOAD ENABLED               = YES
PAYLOAD DOWNLOAD BASE DIR     = \\SeverA\c$\Inetpub\MySite\public_html\en\payloads;\\SeverB\c$\Inetpub\MySite\public_html\en\payloads
PAYLOAD SOURCE BASE DIR       = 
PAYLOAD BASE URL              = http://www.mywebsite.com
PAYLOAD TTL                   = 6
ENABLE ZIP PASSWORD		= YES
PAYLOAD DIR ENCODING LEN	= 20

Download Base Directory:

These locations are configure in the storefront.config file (PAYLOAD DOWNLOAD BASE DIR). This is a location on the file server from which payloads are downloaded by the customer. SendSafe will build and manage subdirectories below this base directory. Into each subdirectory SendSafe will load a specific customer's order.  This order will be maintained in the directory until the download TTL expires.

The download base URL must match the web server's URL for this directory. This base URL will be used to build the download link that will be provided to the customer.

The payload file will be created in a unique obfuscated directory below PAYLOAD DOWNLOAD BASE DIR.

Payload Source:

The payloadloc field can contain a combination of file specs (in either Option A or B file handling) separated by commas and optionally prefixed with operators that determine how each file spec is processed and whether it is included in the file list of files that will comprise a digital payload.

Here's the list of syntax rules and operators:

  1. Payload specs will be separated by commas ','
  2. The reserved word "FFPSOURCED" can be used instead of a file specification. This resevered keyword instructs the Digital Payload generator to use this item's FFP as the source of the digital payload. The WYSIWYG component of the FFP will be rendered as a high resolution file. The name of the file will be: ordernumber.lineitemid.. The syntax for this keyword is:
    1. FFPSOURCED!<EXT>!<DELIVERY>
    2. Each field is ! (exclamation point) delimited
    3. <EXT> is the extent of the high resolution file that is to be generated i.e. PDF, PNG, JPG, etc.
    4. <DELIVERY> is set to either the word "NONE" for manual download by the customer OR a set of parameters that define an FTP connection for automatic upload to a predetermind B2B fulfillment site (typically your printing system). FTP syntax:
      1. <DELIVERY> = "!ftp.mydomain.com!mydirectory!username!password"
      2. For "ftp.mydomain.com!username!password" the username and password are the credentials required to upload a file to the designated FTP location.
      3. If the FTP subdirectory does not exist, the FTP process will create it as a subdirectory under the default path setup in the FP server for this login account.
      4. Here is a complete example of the syntax: FFPSOURCED!PDF!ftp.mydomain.com!mydirectory!username!password
      5. The JSOF Robot configuration ASP FILES SERVER LOC is used as the base directory location from which the /en/ and other web server subdirectories are located when constructing FFPSOURCED HIGH RESOLUTION output files.
  3. An optional character immediately after a comma indicates how the additional payload designation is to be handled.
  4. '@' prefix designates this entry will be ignored by digital payload fulfillment and instead be fulfilled by using an EXTERNAL B2B fulfillment Plugin. B2B is configured in the SendSafe storefront.store.config file. The value entered after the '@' will be passed to the plug-in as a parameter to designate items to be included in a B2B payload.
  5. '#' prefix designates this entry will be ignored by digital payload fulfillment and instead fulfilled by using an INTERNAL Builtin B2B fulfillment center drop shipper . B2B is configured in the SendSafe storefront.store.config file. The value entered after the '#' will be used as a parameter to designate items to be included in a fulfillment drop shipment.
  6. Filenames NOT prefixed with '@' or '#' will be processed as files to be included in a locally assembled and managed digital fulfillment payload.
  7. '+' prefix on a file name means this file will be included in the payload with any prior files.
  8. '^' prefix on a file name means this file will be included in the payload ONLY if the prior file does not exist on the hard disk. This operator provids IF NOT - THEN USE type logic.
  9. '%' prefix on a file name means this file spec is an absolute path. The file specified by this path will be included in the payload along with any prior files. This handling mode will temporarily override a system configured for OPTION B payload handling AND use the absolute path specified after the '%' as one of the source for a payload.
    Note: If you want to override OPTION B handling for an Item with a single file spec, you can place a '%' in front of the file spec.
  10. '~' prefix on a file name means include in the payload only the 1st matching file returned by a wild card file spec. For example: If the file spec = books*.zip and this file spec matches 20 different books on the hard disk, then only the first book from the alphabetized list of matching books will be selected for inclusion in the payload.
    Note: If you want to alter OPTION A or B handling for an Item with a single file spec, you can place a '~' in front of the file spec to get the first matching file.
Here's some examples:
PayloadLoc = c:\payloadsource\filename.exe
This will include the specified file into the digital payload.

PayloadLoc = filename.exe
This will include the Option B path relative specified file into the payload.

PayloadLoc = c:\payloadsource\filename_A.exe,+c:\payloadsource\filename_B.exe
This will include both the specified files filename_A.exe and filename_B.exe into the payload.

PayloadLoc = @W8898,+@W7655
This will process both the specified objects using the B2B plug-in into the payload.

PayloadLoc = #W8898,+#W7655
This will process both the specified objects using the built in B2B drop shippment fulfillment.

PayloadLoc = c:\payloadsource\filename*.exe
This will include all files matching the wild card spec into the digital payload.

PayloadLoc = c:\payloadsource\filename*.exe,^c:\payloadsource\filename_alt*.exe
This will include all files matching the wild card spec filename*.exe into the digital payload. ONLY if nothing matches wild card spec filename*.exe will the file matching c:\payloadsource\filename_alt*.exe be included into the payload.

PayloadLoc = ~c:\payloadsource\filename*.exe
This will include the first file that matches the wild card file spec (sorted alphabetically) into the digital payload.

PayloadLoc = FFPSOURCED!PDF!216.52.183.144!/!myuserid!mypassword
This will generate a high resolution PDF output file and FTP upload it.

PayloadLoc = FFPSOURCED!PNG!ftp.mycompany.com!MyDirectory!myuserid!mypassword
This will generate a high resolution PNG output file and FTP upload it.

PayloadLoc = FFPSOURCED!JPG!NONE
This will generate a high resolution JPG output file and provide download information to the customer.

Option A or B File Handling:
There are two different algorithms that the Robot can use in collecting the "product files" that will be packed into a digital payload. If you do not use product attributes or the attributes do not effect which files are included in a payload, then use "Option A." If you use product attributes and want different "product files" included in the digital payload based on attributes, then use "Option B."

OPTION A:
In "Option A" you must enter the full path & filename (with optional wildcards) into the database for each item that has a digital payload (a product file that is downloaded).

In "Option A" the full path and filename entered into the database Payloadloc field will be the exact location and file that will be added to the payload (if that Item has been ordered). The value of the keyword the PAYLOAD SOURCE BASE DIR  in the configuration file must be set to the words <none> (enclosed in brackets). If <none> is not entered then "Option B" will be enabled.

Product File = Payloadloc

OPTION B:
"Option B" is a powerful way to organize your "product files" into subdirectories based on product attribute (see BuyButton Examples for an example of attributes). This attribute organization is very useful if you have hundreds or thousands of digital products with the same name but different attributes, and the products fit into a few attribute (categories) i.e. Small, medium, and Large... or Beginners, Intermediate, and Pro. If you do not have large numbers of product with the same name which are purchased with attributes, then it is much easier to use "Option A."

In "Option B" you must enter the just the filename (or part of the filename with wild cards) into the database Payloadloc field. You must also enter the base directory location under which all digital product files are located. This location is configured in SendSafe using the PAYLOAD SOURCE BASE DIR keyword in the storefront's configuration file.

"Option B" is enabled by any value in the PAYLOAD SOURCE BASE DIR except the words <none> (enclosed in brackets). If <none> is entered then "Option A" will be enabled.

The attribute value entered for a given product will cause a subdirectory with the same name to be used in the "product file" collection process.

The actual file(s) that are included under "Option B" are selected using the following algorithm:

Product File(s) =  PAYLOAD SOURCE BASE DIR + "\" + ATTRIBUTE + "\" + Payloadloc

Please note that Payloadloc used in this calculations can have "wild cards"as part of the file name. Wildcards will result in all files matching the "wild card" specification being included in the payload. 

The way to organize your "product files" is to place them is subdirectories which have names that match each attribute. Examples:

Example 1: You have three different sizes of decals (with attributes of small,medium,large) that you are selling as digital downloads. Each decal had the same name, but are different sizes.

  1. Create three subdirectories below the PAYLOAD SOURCE BASE DIR; one named Small, one named medium, and one named large.
  2. Place all the Large decals in the large subdriectory
  3. Place all the medium decals in the medium subdriectory
  4. Place all the small decals in the small subdriectory
  5. Set the Payloadloc values in the database for each decal to just the file name of the decal (no path).
  6. Set the ATTRIBUTE for each decal to: "Large, Medium, Small"

SendSafe will load the decales from the large subdirectory if the product attribute is large, from the medium subdirectory if the product attribute is medium, or from the small subdirectory if the product attribute is small.

Example 2: You have three different sizes of decals (with attributes of small,medium,large) that you are selling as digital downloads. Each decal has a different name that ends in small, medium, or large which are the same names for the attributes (i.e. AmericanFlagDecalLarge.jpg, AmericanFlagDecalMedium.jpg, AmericanFlagDecalSmall.jpg).

  1. Create three subdirectories below the PAYLOAD SOURCE BASE DIR; one named Small, one named medium, and one named large.
  2. Place all the Large decals in the large subdriectory
  3. Placeh all the medium decals in the medium subdriectory
  4. Place all the small decals in the small subdriectory
  5. Set the Payloadloc values in the database for each decal to just the file name with a wild card replacing the attribute text at the end of the file name (no path). i.e. AmericanFlagDecalLarge.jpg would be entered into the database as AmericanFlagDecal*.jpg
  6. Set the ATTRIBUTE for each decal to: "Large, Medium, Small"

SendSafe will load the decales from the large subdirectory if the product attribute is large, from the medium subdirectory if the product attribute is medium, or from the small subdirectory if the product attribute is small.

Zip Issues:

The Zip compression function will fail if the directory path contains spaces or other non-alphanumeric characters.

Performance Issues:

Each payload is compressed using standard ZIP compression (with optional password locking). If your system will be generating large numbers of payloads you may want to move the SendSafe robot to a dedicated computer.