Sytze
Sytze

Reputation: 1

Authentication problems with Mulesoft and Salesforce

I have a Mule application which uses the Salesforce connector. When I started developing this application, I first used oAuth to connect to Salesforce, but it kept giving me the following error: Invalid Session ID found in SessionHeader: Illegal Session. Session not found, missing session key: <key>, so I switched to basic authentication for Salesforce.

This has worked great, but now, after some time, the application still throws the Invalid Session ID found in SessionHeader: Illegal Session. Session not found, missing session key: <key> error.

This is unexpected behaviour, since each request contains the username, password and secret token.

It looks to me like some old version is in the Mule cache or something, which makes it want to use the oAuth method again. Is this a possibility?

Any ideas on how to fix this?

Upvotes: 0

Views: 1813

Answers (3)

Arvind Iyengar
Arvind Iyengar

Reputation: 1

In the connector configuration , check for the correct Token code ( generated via sfdc ) .

Update the latest code and try again

Upvotes: 0

Mike M
Mike M

Reputation: 92

@Sytze You need to check the flag in the Salesforce connector for all applications sharing the same user credentials to Disable session invalidation (disableSessionInvalidation="true"). What is likely happening is one of your other applications is invalidating the session while your current app still believes its active.

Upvotes: 0

Naveen Raj
Naveen Raj

Reputation: 801

Your security token that you add with your password while calling it would have expired. Create a new token for you account/email-id in salesforce and use that and it should work

Best would be to use the oAuth to call salesforce.

Upvotes: -1

Related Questions