I create a new user through postman with required inputs(Username, Password, sample1 etc...), once user registered successfully then i need to get a user session through SOAP UI probably am getting issues as an Inavalid_Login Exception.

User Profile : "CustomerCommunityLogin"

Am using System.setPassword for new user through apex code but am getting issue at the time of fetch the SessionId. Is there any possibilities to resolve this issue?

Thanks Venkatsforce

  • Did you use the LoginScope header? – sfdcfox Dec 2 '14 at 15:49
  • No we remove the LoginScopeHeader in Soap ui and tried more time but we didn't get it. – Venkatsforce Dec 2 '14 at 15:50
  • You need to use that header to login as a community user, as I understand it. – sfdcfox Dec 2 '14 at 16:06
  • I tried with LoginScopeHeader and also without LoginScopeHeader but i didn't get it, we are using System.setpassword(UserId,Password) at the time of user creation, but once i resetpassword manually for that particular and then i try it works. I think CustomerCommunityLogin user License having any restrictions for setting password through apex code? – Venkatsforce Dec 2 '14 at 16:15
  • As far as I've noticed, that's usually not true. However, I recall that user provisioning usually takes a moment to register with the Login server, so you simply might not bee waiting long enough between setting the password and logging in. – sfdcfox Dec 2 '14 at 16:17

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.