Symptom
- An attempt to retrieve attachments for a Maintenance Order using API_CV_ATTACHMENT_SRV results in a status code 200 but no data in the response.
- The Entity of the API_CV_ATTACHMENT_SRV being accessed is GetAllOriginals.
Environment
SAP S/4HANA Cloud Public Edition
Reproducing the Issue
1. Use POSTMAN and GET method to retrieve attachment of Maintenance Order using below example URL:
<Host Name>/sap/opu/odata/sap/API_CV_ATTACHMENT_SRV/GetAllOriginals?LinkedSAPObjectKey='<Maintenance Order Number>'&BusinessObjectTypeName='PMAUFK'
User in Authentication: ATTACHMENT_TEST_USER
2. See response status code:200, but no data returned in response body.
Cause
Communication user used for API call does not have corresponding authorization for maintenance order attachment.
Resolution
- Enter app 'Communication Arrangement'.
- Find or create communication arrangement which based on communication scenario 'SAP_COM_0397'.
- Note down the communication user in 'Inbound Communication' section, this user is granted authorization for Attachments service of Maintenance Order and Maintenance Notification.
- Use this user in POSTMAN authentication for API call.
Keywords
API_CV_ATTACHMENT_SRV, GetAllOriginals, Maintenance Order, Attachments, No Data, SAP_COM_0397, POSTMAN , KBA , PM-FIO-2CL , Fiori User Interface (UI) for PM (Public Cloud) , CA-DMS , Document management , Problem