In 2022, SAP Analytics Cloud (SAC) added an OData (Open Data Protocol) API for exporting fact data and master data from a model. This is a departure from the classic data export approach in SAC. Previously, the only strategy for exporting data was for SAC to connect to the data import API of the remote system and manage the upload itself. The export API allows SAC to take advantage of the import infrastructure of the remote system and allow it to connect to SAC as a data source and manage the data transfer. We chose to use OData, to maximize out of the box compatibility. What is OData and how is that related to REST? REST describes the technical communication for invoking a service or getting data. It does not describe the content of the invocation or request. According to odata.org, it is a set of common best practices for building REST interfaces; or “the best way to REST”, as they put it.
If you want to transfer data from an SAC model to a system that supports OData (such as S/4 or Data Warehouse Cloud), you can now do so out of the box. But what if your remote system supports generic REST, but not OData? Then you are going to have to understand how SAC’s OData export API works, to configure that REST consumption. What if you want to implement a custom coded connection from scratch? That’s what this blog post series is about. It will take you on a tour of the export API and how to use it. Over the next days and weeks, it will:
- Cover the preliminary work that you need to do in SAC, to use the export API.
- Take a tour of the actual API in an API tester.
- Create a basic export API wrapper in Python.
- Expand that wrapper, to implement more advanced features, such as filters.
- Lastly, we’ll use the API wrapper that we built to access data from SAC models in a Jupyter Notebook.
I hope that people will find this series useful. When it is complete, it will also be made available as a single tutorial mission.