
In the latest SAP IBP 2502 release, SAP introduced SAP_COM_0A72 – Planning - Detailed Pegging Data Read, an API designed for pegging data extraction, enabling integration with external systems.
SAP has provided official documentation, which you can check out at this link:
🔗SAP IBP Detailed Pegging Data Read API Documentation
Additionally, you can test the API in the SAP Business Accelerator Hub using the link below:
🔗Test IBP_DetailedPeggingService API
However, while attempting to execute the process, I found that some key points were not entirely clear in the documentation.
For that reason, I created this detailed post to guide you through the process. I hope it proves useful for anyone looking to explore this new functionality!
So, let's get started with our step-by-step guide! 🚀
First, we need to create two communication arrangements:
Creating the communication arrangements is straightforward:
Repeat this process for the SAP_COM_0A72 scenario. You can use the same Communication System and Communication User.
Ok, now you have everything set up on the IBP side to call the APIs.
We can proceed in two ways: either by using SAP's website to test the API or by using API testing software such as Postman. In this case, we will use SAP's website.
The first step is to create our snapshot. To do this, go to:
https://api.sap.com/api/IBP_Snapshot_RAP_ODataService/tryout
Once the page loads, go to "Select Environment" and create a new environment.
On this screen, you need to fill in the following parameters:
First, we will execute the GET method:
Next, we will execute the POST method:
The last transaction for the snapshot is:
Now, let’s get to work!
⚠️Before anything else, don’t forget to select the environment we created.
First, let’s execute the GET method:
Now, we need to generate the token. To do this, go to the Headers tab:
Click "Run" and check the result in the "Response Body" tab.
Since you haven’t created a snapshot yet, the response will likely be empty. However, in my case, it listed all previously created snapshots.
Now, let’s execute the POST method:
In the Headers tab:
{
"IBPTransaclSnpshtDesc": "Detailed Pegging in PLANNINGAREA VERSION",
"IBPTransaclSnpshtID": "TEST BLOG",
"PlanningAreaID": "YOUR_PA_ID",
"VersionID": "BASELINE",
"_IBPDetldPggngSnpshtFilter": {
"_IBPDetPggngPrimDmndDTpFilter": [
{
"Operator": "EQ",
"PrimaryDemandDocTypeValueFrom": "SD_ITM"
},
{
"Operator": "EQ",
"PrimaryDemandDocTypeValueFrom": "DEL_ITM"
},
{
"Operator": "EQ",
"PrimaryDemandDocTypeValueFrom": "DSTR_ITM"
},
{
"Operator": "EQ",
"PrimaryDemandDocTypeValueFrom": "FCST"
}
],
"_IBPDetPggngUnpSplIsSplFltr": [
{
"Operator": "EQ",
"UnpeggedSupplyIsSplit": true
}
],
"_IBPDetPggngPeggingLvlFltr": [
{
"Operator": "LT",
"PeggingLevelValueFrom": 6
}
],
"_IBPDetPggngPrimDmndRTFltr": [
{
"Operator": "BT",
"PrimaryDemandReqdTimeValueFrom": "2024-05-01T00:00:00Z",
"PrimaryDemandReqdTimeValueTo": "2025-12-31T00:00:00Z"
}
]
}
}
Click Run and check the results!
You will see that the request was executed successfully, and the response includes the Snapshot ID (IBPTransaclSnpshtUUID). We will use this ID in the next step. Please take note.
Also, note that the snapshot status is set to "INITIAL", meaning it is not yet ready to be extracted.
For the snapshot to be extractable, its status must change to "EXTRACTABLE".
Now, let's calculate the snapshot using the POST method:
Steps:
⚠️Important: The x-csrf-token is only valid for the current session and is not a permanent ID. If the session expires, you will need to generate a new token.
All set! Now our snapshot has the status "EXTRACTABLE", meaning it is ready for data extraction. 🎉
Important Note: Snapshots have an expiration time after they are calculated. Their validity lasts for 6 hours, after which they lose the "EXTRACTABLE" status.
How to extend the snapshot validity:
You can use the POST method:
🔹POST /IBPTransaclSnapshot({IBPTransaclSnpshtUUID})/SAP__self.ExtendSnapshotValidity
How to delete a snapshot:
If needed, you can delete a snapshot using the DELETE method:
🔹DELETE /IBPTransaclSnapshot({IBPTransaclSnpshtUUID})
This ensures you can manage your snapshots efficiently!
Now, let's move on to our second API, where we can extract the snapshot data:
🔗IBP Detailed Pegging Service API
This API is very simple—it only has a GET method:
You can apply filters, choose specific data, or simply run it.
⚠️Reminder: Don’t forget to configure the environment just like we did for the Snapshot API!
And that's it, everyone! 🎉 The data is now ready in a structured format. 🚀
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
5 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 | |
1 |