SAP Knowledge Base Article - Public

2879938 - Field "fileContent" is not returning in Recruiting API query on Attachment entity - SuccessFactors OData API

Symptom

The field "fileContent" is not present in the payload results when you query Attachment entity of Recruiting module.

NOTE: This scenario is applicable for recruiting attachments only.

Environment

  • SAP SuccessFactors HXM Suite
    • OData API

Reproducing the Issue

  1. Perform the query below

    https://<apiurl>/odata/v2/Attachment?$top=1&$filter=module eq 'RECRUITING'

  2. Field "fileContent" is not present in the results

OR

  1. Perform the query below

    https://<apiurl>/odata/v2/Attachment?$top=1&$filter=module eq 'RECRUITING'&$select=fileContent

  2. Error message below returns

    [COE0020]Direct access to Attachment fileContent of module in blocklist is forbidden due to GDPR(General Data Protection Regulation).

Cause

This is an expected behavior when RAL is enabled. Refer to the note below taken from the "Recruiting" section of page Important Notes About Read Audit | SAP Help Portal:

"When read audit is enabled, the fileContent property is hidden from query responses for all Recruiting attachments (module property value is RECRUITING)."

Resolution

The "fileContent" field won't be returned when RAL is enabled.

To get the fileContent field in your API response, you'll need to check whether it's acceptable to turn off RAL for your use case. More details about in pages Read Audit | SAP Help Portal.

If disabling RAL is appropriate for your scenario, follow these steps:

  1. Go to Manage Audit Configuration screen
  2. Select Read Audit tab
  3. Switch off the "Read Access Logging" option

Once RAL is disabled, the fileContent field will be returned in the API response.

See Also

2620222 - 1802 RAL (Read access log) patch for SF preview instances

2617644 - [1802] [Data Protection and privacyCompliance] API Audit Logs behavior after 1802 release (In Preview and Production SF Instances)

Keywords

successfactors, api, odata, rcm, COE0020, query, not visible, base64, ral, read audit logging , KBA , LOD-SF-RCM-API , Webservices & APIs , Problem

Product

SAP SuccessFactors HCM Suite all versions