SAP Knowledge Base Article - Public

2675452 - Error HTTP 401 Unauthorized Between Cloud Platform Integration and SAP ERP/CRM/S4H When Sending Data from Cloud for Customer to SAP ERP/CRM/S4H


You are sending data from Cloud for Customer to SAP ERP/CRM/S4H via Cloud Platform Integration(CPI) and the message fails in CPI with error HTTP 401 Unauthorized.


  • SAP Hybris Cloud for Customer
  • Cloud Platform Integration
  • S/4HANA
  • CRM

Reproducing the Issue

Steps in C4C

  1. Login to C4C.
  2. Go to Webservice Message Monitoring.
  3. Check the failed outgoing message with error "HTTP 500 Internal Server Error".
  4. Navigate to error log, you can find MPL ID.

Steps in CPI

  1. Login to CPI.
  2. Go to Message Monitor.
  3. Search with MPL ID captured in the C4C outgoing message.
  4. You can find the error "HTTP 401 Unauthorized while communciating with XYZ" where XYZ stands for ERP/CRM/S4H URL


There could be multiple reasons for this problem. Check the below mentioned points, you should be able to identify the problem


  1. Check the user (Integration user on ERP) has the correct roles(SAP_SD_COD_INTEGRATION or SAP_SD_COD_INTEGRATION_EXT) assigned.
  2. Check for the user validity if it is expired.
  3. Ensure that the integration user is not locked.
  4. Ensure that the password defined for the integration user in CPI/PI is correctly defined.
  5. Ensure that the CPI client certificate is mapped to the integration user in ERP/CRM/S4H.
  6. In ERP/CRM/S4H , go to tcode SM30 , open the table VUSREXTID => DN => the filed "min" has either an empty value or is filled with a date(date when the certificate is valid from).
  7. Ensure that the icm parameters(icm/HTTPS/trust_client_with_subject and icm/HTTPS/trust_client_with_issuer) are maintained(SMICM => GoTo => Parameters => Display)

Note : Incase the issue still persists after all the above confiuration is in place, we would ask you to create an case from One Support Launchpad to component LOD-HCI.
Clearly mention that the problem is in CPI/PI while sending data from C4C to your On-Premise system.

See Also

Online Help page: SAP Cloud Platform Integration


"HTTP 401 Unauthorized"  "401"  "Unauthorized" "401 Unauthorized" , KBA , LOD-CRM-INT-ERP , Integration of C4C with ERP , LOD-CRM-INT-S4H , Integration of C4C with S/4 HANA , LOD-CRM-INT-CRM , Integration of C4C with CRM , Problem


SAP Cloud for Customer core applications 1805 ; SAP Cloud for Customer core applications 1808 ; SAP Cloud for Customer core applications 1811