SAP Knowledge Base Article - Preview

3801408 - Related Objects Type Codes for REST API

Symptom

When creating or linking business objects via the SAP Sales Cloud V2 REST API using the relatedObjects array, the correct type code must be specified for the linked object. Customers encounter issues where:

  • A linked object does not appear in the frontend after creation via API.
  • The wrong business object type is referenced, causing silent failures or missing relationships.

A common example: when creating a Task via POST and linking it to a Visit, using type: "542" (Task) instead of the correct type: "2054" (Visit) results in the visit link not appearing in the frontend.


Read more...

Environment

• SAP Sales Cloud Version 2 
• SAP Service Cloud Version 2 
• SAP Sales Cloud and SAP Service Cloud Version 2 

Product

SAP Sales Cloud Version 2 all versions ; SAP Sales Cloud and SAP Service Cloud Version 2 all versions ; SAP Service Cloud Version 2 all versions

Keywords

relatedObjects, sourceType, type code, REST API, Visit, Task, Appointment, Lead, Opportunity, Sales Quote, API integration, linked objects, related entities, , KBA , CEC-CRM-CQP , Sales Quote for SAP Sales/Service Cloud , CEC-CRM-CAS , Case Management for SAP Sales/Service Cloud , CEC-CRM-EML , Emails for SAP Sales/Service Cloud , CEC-CRM-VST , Visit for SAP Sales/Service Cloud , CEC-CRM-TSK , Task for SAP Sales/Service Cloud , CEC-CRM-LEA , Lead for SAP Sales/Service Cloud , CEC-CRM-APT , Appointment for SAP Sales/Service Cloud , CEC-CRM-SO , Sales Order for SAP Sales/Service Cloud , CEC-CRM-GS , Guided Selling/Opportunity for SAP Sales/Service Cloud , How To

About this page

This is a preview of a SAP Knowledge Base Article. Click more to access the full version on SAP for Me (Login required).

Search for additional results

Visit SAP Support Portal's SAP Notes and KBA Search.