#g4slkch_uploadFile

  *//////////////////////////////////////////////////////////////*          
  * #g4slkch_uploadFile - Upload File                            *          
  *                                                              *          
  * Input:                                                       *          
  *   in_parameter (required) - The parameter name.              *          
  *   in_value (required) - The value of the parameter.          *          
  *                                                              *          
  * Output:                                                      *          
  *   out_errMsg - The error message (if error exists).          *          
  *                                                              *          
  * Returns:                                                     *          
  *   Slack File ID for success, blank for error.                *          
  *                                                              *          
  * Settable Variables ([r]=required)                            *          
  *   id - The Slack ID to use [r]                               *          
  *   team - The Slack Team to use [r]                           *          
  *   upload_file - The fully qualified path to the file you     *          
  *     wish to upload.                                          *          
  *   channel_list - An optional list of comma separated channel *          
  *     IDs to share the file on.                                *          
  *   upload_ccsid - The CCSID to use (1252)                     *     
  *   debug - Turn on Debug (*NO, *YES)                          *     
  *   debug_file - The debug file name.                          *     
  *                 (/tmp/g4g_[id]_uploadFile.txt)               *     
  *                                                              *     
  *//////////////////////////////////////////////////////////////*     
 D #g4slkch_uploadFile...                                              
 D                 PR           256                                    
 D  out_errMsg                  256    Options(*NOPASS)                

#g4slk_uploadFile is used to upload a file to your slack team. If you specify 1 or more optional channels (separated by commas) the file will be shared on those channel(s).

Returns: The id of the file uploaded, or blank for error.

Optional Parameters:

  • Error Message (output) - Error message

Settable Variables (use #g4slk_setValue)

  • id (required) - The Slack ID to use to upload the file.
  • team (required) The Slack Team to use to upload the file to.
  • upload_file - The fully qualified path to the file you wish to upload.
  • channel_list - An optional comma separated list of Channel IDs to share the file on. If no channels are listed the file will remain private,
  • upload_ccsid - The CCSID to use. The default is 1252.
  • debug - Specify *YES to turn on debug, or *NO to turn off debug. The default is *NO.
  • debug_file - Specify the fully qualified file name for the main debug file. The default is /tmp/g4slk_[id]_uploadFile.txt.