SAP Home Learn Build Integrate Model Operate Extend with AI ConnectTutorial navigator Knowledge Graph API Devtoberfest Developer Advocates App Space

Manage my Account SAP Devs YouTube ↗ Learnings ↗ Community ↗ Provide Feedback ↗
Logout
โคข Open full site

Create a CAP Service with BAS Productivity Tools

Create a SAP Cloud Application Programming model (CAP) service using the productivity tools in SAP Business Application Studio.

Overview

🎓 beginner 30 min. SAP BuildBeginnerSAP Business Technology PlatformSAP Build Apps Enterprise EditionSAP Cloud Application Programming ModelSAP Business Application Studio

You will learn

  • โœ”How to build a CAP service with low-code tools
  • โœ”How to create roles to enable authorization for your data entities
  • โœ”How to deploy your CAP service to SAP BTP
Daniel Wroblewski D Daniel Wroblewski December 4, 2023
Created by August 3, 2023
Contributors

Prerequisites

Prerequisites

Steps

Intro

You will quickly build a Risk Management service with 2 entities: Risks and Mitigations. Each risk can have 0 or 1 mitigations, while mitigations can be assigned to multiple (or no) risks.

Another key feature is the creation of roles, one for viewer of the data and one for manager, meaning a person who can update the data. The role, exposed in SAP BTP as a role collection, can be assigned to a user once the service is deployed.

You must set up your SAP BTP tenant with SAP HANA Cloud and SAP Build Apps โ€“ your deployed CAP service and SAP Build app must be on the same tenant. For this tutorial, we will assume you are using a trial account.

You can use SAP Business Application Studio on any tenant, and when it comes time to deploy, deploy the service on the tenant with your SAP HANA Cloud and SAP Build Apps.

Step 1 Create SAP Business Application Studio project
โ€”

These steps open SAP Business Application Studio in the traditional way, without using SAP Build’s lobby.

  1. Open the your subaccount, making sure Instances and Subscriptions on the left-side menu is selected.

    Click SAP Business Application Studio.

    Open BAS
    Open BAS

  2. After opening SAP Business Application Studio, click Create Dev Space.

    Create dev space
    Create dev space

    Enter a name for your dev space, select Full-Stack Application Using Productivity Tools, and then click Create Dev Space.

    Create LCNC dev space
    Create LCNC dev space

    The dev space will be created, and you will see that is being started.

    Starting dev space
    Starting dev space

    Soon it will say Running.

    dev space runnings
    dev space runnings

  3. Click the dev space name to open it, and you will the main canvas of SAP Business Application Studio.

    dev space runnings
    dev space runnings

  4. Click Create Project.

    Create project
    Create project

    Select the Full-Stack Project generator, and click Start.

    Create project
    Create project

    For the name of the project, enter RiskManagement, and then click Finish.

    Create project
    Create project

    BAS will generate the project and all the files, and you will see the following, where you can create data models, the services that will expose the data, and more:

    Create project
    Create project

Step 2 Create data model
+
Step 3 Create service
+
Step 4 Add sample data
+
Step 5 Add user roles
+
Step 6 Deploy project to SAP BTP
+
Step 7 Check service
+

Resources

Discussion

Share feedback on this tutorial or join the conversation in SAP Community.

Submit detailed feedback Discuss in Community
Steps
Step 1 of 7
1. Create SAP Business Application Studio project 2. Create data model 3. Create service 4. Add sample data 5. Add user roles 6. Deploy project to SAP BTP 7. Check service

Learn more →