Giter Club home page Giter Club logo

sfattachmentsdownload's Introduction

SfAttachDownload

Purpose:

Download all Customer's attachments (that are displayed as separate emails) to provided folder (or to current dir) and upload them on ftp (if needed).

Prerequisites

Java should be installed, ftp for case should be created in advance.

Prerequisites for Linux:

SALESFORCE_USERNAME and SALESFORCE_PASSWORD environment variables.
SALESFORCE_PASSWORD should have a format like passwordSecurityToken.

In order to run the program

  1. download download.jar
  2. start it with needed parameters, examples:
  • Windows, the first run of the program: java -jar download.jar -c 12345678 -u [email protected] -p passwordToken.
  • Windows, all subsequent runs: java -jar download.jar -c 12345678
  • Linux: java -jar download.jar -c 12345678

salesforce-attachments-download usage:

-c, --caseNumber <8_digit_value> required
-d, --destinationFolder <target_for_downloads> optional, by default current_dir\case_number
-u, --userName <SF_username> required on Windows for the first run only
-p, --passwordToken <SFpasswordToken (no spaces)> required on Windows for the first run only
-t, --threads <number_of_threads> optional, by default equal to available CPUs-1
-o, --only <0, 1 or nothing> optional, if 1 then download only the latest attachment(s), if 0 - only the first, by default download all files
--help prints this usage text

How to generate SalesForce security token

  1. login to SalesForce
  2. in the top right corner click on your name -> My settings
  3. click Personal -> Reset My Security Token, or enter 'reset' in quick find

You'll receive an e-mail with a new token.

Remarks

  1. Already downloaded file won't be downloaded again
  2. If there are several attachments with the same name, the newest will be downloaded as is, all the rest will have GUID in their names
  3. As a side-effect of point 2, file with GUID in its name will be downloaded again
  4. Encrypted password will be stored in %userprofile%\Documents\salesforce-attachments-download.txt

sfattachmentsdownload's People

Contributors

kshakhmatova avatar

Watchers

 avatar

Forkers

4iji

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.