SAP Knowledge Base Article - Public

2843653 - How to download files from Document Center using REST API calls - Onboarding 1.0

Symptom

How to download files from Document Center using the Document Center REST API calls?

Image/data in this KBA is from SAP internal systems, sample data, or demo systems. Any resemblance to real data is purely coincidental.  

Environment

SAP Successfactors Onboarding 1.0

Resolution

    1. The first API method to be used is the authenticate method. In below sample, the API will be used in the SAP demo environment. The URL to be used needs to be replaced by the URL of your Onboarding instance, sample: https://sales-onboarding8.sapsf.com/ONBPREM/api.ashx/authenticate?AccountName=YOUR_ACCOUNT_NAME&UserName="WEBSERVICE_LOGIN"&Password="WEBSERVICE_PASSWORD"

    2019-09-26_15-21-20.png

    1. The next step will be copy the authentication token, present in the Cookies section;
    2. Open a new tab in your API development tool and in the headers section and create a POST method;
    3. In the Headers section include the value Cookie copied from your previous tab;
    4. In content type, select the type application/json;

2019-09-26_15-23-42.png

  1. The next step will be define the filters for your search, for this particular search we are using the document name and searching for the US W4 form. For more information about these filters names, please refer to: Onboarding and Offboarding API
  2. There's a copy of this filter attached in this article, please refer to the file: filter.txt;
  3. The final step will be send your call and download the file.

2019-09-26_15-25-04.png

See Also

Onboarding and Offboarding API

Keywords

REST, API, Document Center, bulk, download, upload , KBA , LOD-SF-OBD , Onboarding , LOD-SF-OBD-API , Webservices & API's , How To

Product

SAP SuccessFactors Onboarding

Attachments

filter.txt