Saturday, May 15, 2010

S4S web.config settings to use the Sandbox API

The following web.config applicationSettings can be used to override the default Partner API URL for S4S.

Note: The setting names will alter with updates to S4S as the Salesforce Partner API is updated.

        <sectionGroup name="applicationSettings" type="System.Configuration.ApplicationSettingsGroup, System, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089" >
            <section name="FuseIT.Sitecore.SalesforceConnector.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089" requirePermission="false" />
            <setting name="Sitecore_Salesforce_SalesforcePartner170_SforceService"
            <setting name="FuseIT_Sitecore_SalesforceConnector_SalesforceMetadata160_MetadataService"

As of 1.4 the preferred approach is to change the binding environment in the connection string. E.g.

  <add name="S4SConnString" connectionString="S4S:user id=user_name;password=user_password;token=user_security_token;environment=Sandbox" />



user id

The Salesforce user name that will be used to establish the Partner API session


The password for the Partner API user. If the servers IP address isn’t trusted by the Salesforce Organization being connected to the users security token can be appended to the password.


(Optional) As an alternative to appending the users security token to the password in the connection string it can be defined separately to provide the same functionality.


(Optional) The type of Salesforce environment being connected to. Defaults to Production if unspecified which will also work for developer edition organizations if required.

Possible values:

  • Production
  • DeveloperEdition
  • Sandbox
  • Pre_release