Alteryx Designer Desktop Knowledge Base

Definitive answers from Designer Desktop experts.

How to: Use the Salesforce Output Tool without a Salesforce Security Token

SabrinaCB
Alteryx Alumni (Retired)
Created

How To: Use Salesforce Output tool without a Salesforce Security Token

Some organizations set up their Salesforce users to not use a Security Token. This is done by setting an acceptable range of IP addresses instead in Salesforce Admin. This article will walk you through how to modify the Salesforce Output tool so that it may be used without a Salesforce Security Token.
 

Issue

Without the work-around users are able to sign in on the GUI of the tool without a token successfully:
 

idea Skyscrapers

However when running the workflow they will receive error Parse at char(0): Type mismatch in operator +.(Expression #3)
 

idea Skyscrapers


Prerequisites

  • Alteryx Designer, Server
    • All Versions affected
  • Salesforce Output Tool
    • Version 1.3.1
  • Salesforce account set up to not use a Security Token. This is usually managed by the SFDC Admin.
    This can be checked in the Administer Section --> Security Controls --> Network Access section.
 
  • idea Skyscrapers


Procedure

1.   To implement work-around, start with the workflow that is receiving the error shown above.  

2.   Right-click on Salesforce Output tool and click "Open Macro".


idea Skyscrapers


3.   In the macro, navigate to the "get access token" container and click on the Formula tool.


idea Skyscrapers

 
4.   In the "query_body" formula, remove "[security token]" from the formula.


idea Skyscrapers

 
5.   Formula should now look like this:


idea Skyscrapers

 
6.   Save the macro. This will now modify the tool permanently in the tools folder and can be used without a Security Token in any workflow.


idea Skyscrapers

 
7.   Users will now be able to run this workflow, and any other workflows on this machine with this tool successfully.


idea Skyscrapers



   


Notes

The Salesforce Input tools (both the Deprecated version and Python-based 4.x versions) do not encounter an issue running locally without a Salesforce Security Token.

If you encounter any issues or have questions on the above, please contact Alteryx Support.

Comments
Amadeu_gustavo
7 - Meteor

I'm doing this alterations, but I could use a conditional formula to use Token's access if it isn't null?

Also, when I upload the flow to Gallery without Token (it also happens in Salesforce Input Tool) it comes a authentication error, something about cryptography method is not supported. 

if 
	!isNull([security_token]) then
'<?xml version="1.0" encoding="utf-8" ?>
	<env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
  <env:Body>
    <n1:login xmlns:n1="urn:partner.soap.sforce.com">
      <n1:username>' + [username] + '</n1:username>
      <n1:password>' + [password] + [security_token] + '</n1:password>
    </n1:login>
  </env:Body>
</env:Envelope>'
	else
'<?xml version="1.0" encoding="utf-8" ?>
	<env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xmlns:env="http://schemas.xmlsoap.org/soap/envelope/">
  <env:Body>
    <n1:login xmlns:n1="urn:partner.soap.sforce.com">
      <n1:username>' + [username] + '</n1:username>
      <n1:password>' + [password] + '</n1:password>
    </n1:login>
  </env:Body>
</env:Envelope>'
endif