HR integration how to connect to Successfactors

Max10
Mega Contributor

Hello!

 

I try to configure the interface between SuccessFactors and ServiceNow by using the HR Integrations Application.

 

I now followed the instructions on https://docs.servicenow.com/bundle/newyork-hr-service-delivery/page/product/human-resources/concept/...

and followed them step by step.

Unfortunately, it is not working now and I get the following errors in the log:

 

1.     Failed to retrieve login session token from SuccessFactor

2. ..... Method failed: (/sf/start/) with code: 400

3.  SuccessFactors  ......  Status: 400 Error:

 

If I go through the links manually in my browser, then I can use the credentials successfully.

 

I configured SOAP and REST.  But I found the message in the SuccessFactors SOAP interface : 

Please Note - SFAPI is depricated as of August 1, 2018. Please use OData for new development and consider moving your legacy applications and integrations to OData.

 

Question:

 

1) Can anyone help me with the error messages? What do they mean? What do I need to change?

2) What is with the message regarding the SFAPI in SuccessFactors?

 

Many thanks, any help is welcome!

 

19 REPLIES 19

@tomjuk26 In SuccessFactors do you have API access allowed in the instance? This seems to be the root of your issue. You can find these details on the SuccessFactors site here.

Regards,

Mike

Thanks for your reply @michaelj.sheridan ,

I don't have access to view the API permissions in SuccessFactors (SF) but I have checked with the team who manage SF and they have advised that the user account does have the access as per the link you provided.

With the SOAP message functions listed in the 'HR SOAP Services / Success Factor Compound Employee Sync', do these need to be edited?

E.g. the 'login' SOAP Message Function has the following xml listed:

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:urn="urn:sfobject.sfapi.successfactors.com">
<soapenv:Header/>
<soapenv:Body>
<urn:login>
<urn:credential>
<urn:companyId>${credential.companyId}</urn:companyId>
<urn:username>${credential.username}</urn:username>
<urn:password>${credential.password}</urn:password>
<!--Optional:-->
<urn:developerKey>${credential.developerKey}</urn:developerKey>
</urn:credential>
<!--Zero or more repetitions:-->
<urn:param>
<urn:name>${param.name}</urn:name>
<urn:value>${param.value}</urn:value>
</urn:param>
</urn:login>
</soapenv:Body>
</soapenv:Envelope>

Do I need to edit the 'urn:company', 'urn:username', 'urn:password' fields in the XML code? Or does ServiceNow pick up these values from the 'Sources' configuration where the SOAP and REST credentials are set up?

Thanks again for your help,

Tom

@tomjuk26 Those values are taken from the Source, SOAP and OAuth configurations. I think you can try a test and set a bad password and see if this changes the message (the error goes from no access to API to failed authentication). This will be a good indication to confirm the user does not have API permission, if this is the case.

Regards,

Mike

 

Hi @michaelj.sheridan,

There was some permissions missing on the API account which have now been resolved.

I can get the sync to work but only if I manually add the username, password and company ID in the 'login' SOAP message function.

<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:urn="urn:sfobject.sfapi.successfactors.com">
<soapenv:Header/>
<soapenv:Body>
<urn:login>
<urn:credential>
<urn:companyId>${credential.companyId}</urn:companyId>
<urn:username>${credential.username}</urn:username>
<urn:password>${credential.password}</urn:password>
<!--Optional:-->
<urn:developerKey>${credential.developerKey}</urn:developerKey>
</urn:credential>
<!--Zero or more repetitions:-->
<urn:param>
<urn:name>${param.name}</urn:name>
<urn:value>${param.value}</urn:value>
</urn:param>
</urn:login>
</soapenv:Body>
</soapenv:Envelope>

Do the above values get populated from the values set in the HR Integration Source section (Ref: Provide source credentials for the SuccessFactors service | ServiceNow Docs)?

Thanks

Tom

@tomjuk26 They do get populated when the job runs, but not when you run the SOAP function manually. The OAuth of the To Do functions allow you to test that manually without putting in the details because it is using the profile you set for OAuth.

Regards,

Mike