SAP SuccessFactors uses an OData interface to extract data.
Adding the TimeXtender OData data source
- Create a new TimeXtender OData data source connection
- Add the Base URL. For more information please see SAP’s OData documentation. Some examples of what the Base URL should look like are provided below:
https://api10preview.sapsf.com/odata/v2/
https://api10preview.sapsf.com/odatav4/ - Choose an authentication method and enter the credentials. It is possible to use Basic authentication with the user formatted as <username>@<SF_tenant/company_code> as documented in SAP Basic authentication documentation. Alternatively, select OAuth2 as the authentication method, and enter the Client ID and Client Secret as documented in SAP’s OAuth2 documentation.
- On each endpoint add Table flattening
- Paste the below XSLT into the transformation section
<?xml version="1.0" encoding="UTF-8" ?> <xsl:stylesheet version="1.0" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xmlns:tx_tns_1="http://www.w3.org/2005/Atom" xmlns="http://www.w3.org/2005/Atom" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" > <xsl:output method="xml" indent="yes" /> <xsl:template match="/"> <tx_root> <xsl:element name="{//tx_tns_1:title}"> <xsl:apply-templates select="/tx_tns_1:feed/tx_tns_1:entry/tx_tns_1:content/m:properties" mode="rows"/> </xsl:element> </tx_root> </xsl:template> <xsl:template match="/tx_tns_1:feed/tx_tns_1:entry/tx_tns_1:content/m:properties" mode="rows"> <xsl:element name="{//tx_tns_1:title}"> <xsl:for-each select="../../*[not(self::tx_tns_1:content or self::tx_tns_1:link)]"> <xsl:element name="entry_{name()}"> <!-- <xsl:copy-of select="@*"/> --> <xsl:value-of select="."/> </xsl:element> </xsl:for-each> <!-- copy all elements --> <xsl:for-each select="*"> <xsl:element name="{local-name()}"> <!-- <xsl:copy-of select="@*"/> --> <xsl:value-of select="."/> </xsl:element> </xsl:for-each> <!-- <xsl:for-each select="../../tx_tns_1:link"> <xsl:element name="{local-name()}"> <xsl:copy-of select="@*"/> <xsl:value-of select="."/> </xsl:element> </xsl:for-each> --> </xsl:element> </xsl:template> </xsl:stylesheet>
- Give the flattened table the same name that the non-transformed endpoint has
- Enable the setting Show flattened tables only