Skip to content
IT Canvass
SAP APIs · Lesson

CDS APIs

Quick answer

CDS-based APIs embody code-to-data and clean-core: define the model once, expose it as a service, and consume it everywhere.

Key takeaways

  • CDS views define rich, reusable data models on HANA (joins, aggregations, associations, annotations).
  • The ABAP RESTful Application Programming model (RAP) is the strategic framework: you define behaviour on CDS entities and bind them…
  • In modern SAP, CDS is the primary way to build APIs and the data behind Fiori.
  • Watch out: Bypassing CDS with hand-built services.

CDS as the API foundation

CDS views define rich, reusable data models on HANA (joins, aggregations, associations, annotations). By annotating a CDS view (or using a RAP service definition/binding), you expose it as an OData API, so the same model powers Fiori, analytics and external integration. This is the modern, low-effort path to SAP APIs.

How it works

@OData.publish: true
define view entity Z_C_SalesOrder as select from I_SalesOrder { ... }
" → generates an OData service consumable by Fiori and integrations

RAP and service binding

The ABAP RESTful Application Programming model (RAP) is the strategic framework: you define behaviour on CDS entities and bind them as OData (V2 or V4) services. This produces robust, transactional APIs for both UIs and integration, aligned with clean-core and cloud.

Why it matters

CDS-based APIs embody code-to-data and clean-core: define the model once, expose it as a service, and consume it everywhere. For modern SAP development and integration, CDS + OData (via RAP) is the standard, and a key skill.

Common pitfalls

  • Bypassing CDS with hand-built services.
  • Ignoring annotations that generate/shape the API.
  • Not using RAP for transactional APIs.

Want to learn this properly?

Our live, instructor-led SAP Training covers this hands-on, with real projects and a certification path.

Check your understanding

  1. Which statement is true of CDS APIs?

    • A. Working with IDocs in ABAP means generating, processing and enhancing the intermediate documents SAP uses for…
    • B. Methods are the operations of ABAP classes, the callable units of behaviour.
    • C. By annotating a CDS view (or using a RAP service definition/binding), you expose it as an OData API, so the…
    Show answer

    C. By annotating a CDS view (or using a RAP service definition/binding), you expose it as an OData API, so the…

    Covered in the “CDS as the API foundation” section of this lesson.

  2. Which of these also applies to CDS APIs?

    • A. Learning screens in isolation instead of the flow.
    • B. This is the modern, low-effort path to SAP APIs.
    • C. Textbook answers without practical grounding.
    Show answer

    B. This is the modern, low-effort path to SAP APIs.

    Covered in the “CDS as the API foundation” section of this lesson.

  3. Which part of the Learn SAP curriculum covers CDS APIs?

    • A. SAP security
    • B. SAP HANA
    • C. SAP APIs
    Show answer

    C. SAP APIs

    This lesson sits in the SAP APIs section of the Learn SAP course.

Frequently asked questions

What does the term CDS APIs refer to in SAP?

CDS-based APIs expose SAP data models as services, especially OData, directly from Core Data Services views. In modern SAP, CDS is the primary way to build APIs and the data behind Fiori.

What is connected to CDS APIs in an SAP landscape?

CDS views define rich, reusable data models on HANA (joins, aggregations, associations, annotations).

What is the practical takeaway on CDS APIs?

CDS-based APIs embody code-to-data and clean-core: define the model once, expose it as a service, and consume it everywhere.

What tends to go wrong with CDS APIs?

Bypassing CDS with hand-built services. Ignoring annotations that generate/shape the API. Not using RAP for transactional APIs.
CallWhatsAppEnquire