SAP Knowledge Base Article - Public

3113212 - SFAPI login error with HTTP 500 error and "Failed to execute the ExtractVariables: ExtractCompanyId"

Symptom

You are trying to login into SFAPI using your username/password and you get errors like HTTP 500 or the error below:

{"Envelope":{"encodingStyle":"http:\/\/schemas.xmlsoap.org\/soap\/encoding\/","Body":{"Fault":{"faultcode":"soap:Server","faultstring":"Failed to execute the ExtractVariables: ExtractCompanyId","faultactor":{},"detail":{"source":{"errorcode":"steps.extractvariables.ExecutionFailed"}}}}}}

Environment

  • SAP SuccessFactors HXM Suite
    • SFAPI login operation

Reproducing the Issue

You are running your API POST call with SF endpoint:

https://apiXXXX.sapsf.com/sfapi/v1/soap?wsdl    (this endpoint depends of the datanceter).

 And you are trying to do POST > Login operations

<Envelope xmlns="http://schemas.xmlsoap.org/soap/envelope/">
    <Body>
        <login xmlns="urn:sfobject.sfapi.successfactors.com">
            <credential>
                <companyId>YOUR_COMPANY_ID</companyId>
                <username>YOUR_USER</username>
                <password>has_special_chars_like_$_&_@_#_>_"_and_others/password>
            </credential>
        </login>
    </Body>
</Envelope>

Cause

Password with special characters.

Resolution

Please change the password:

  • Ensure that your password doesn’t contain the XML special character &, <,  >, "

Keywords

SFAPI, SOAP, Login, error, HTTP 500, ECP, ping, CompoundEmployee, {"Envelope":{"encodingStyle":"http:\/\/schemas.xmlsoap.org\/soap\/encoding\/","Body":{"Fault":{"faultcode":"soap:Server","faultstring":"Failed to execute the ExtractVariables: ExtractCompanyId","faultactor":{},"detail":{"source":{"errorcode":"steps.extractvariables.ExecutionFailed"}}}}}}, SAP SuccessFactors API , KBA , LOD-SF-INT-API-DEPR , SFAPI Deprecation Queries , LOD-SF-INT , Integrations , LOD-SF-INT-API , API & Adhoc API Framework , LOD-SF-INT-CE , Compound Employee API , LOD-SF-INT-ECP , SF EC to ECP API's & Connectivity Issues Only , How To

Product

SAP SuccessFactors HCM Suite all versions