Technology Blogs by SAP
Learn how to extend and personalize SAP applications. Follow the SAP technology blog for insights into SAP BTP, ABAP, SAP Analytics Cloud, SAP HANA, and more.
cancel
Showing results for 
Search instead for 
Did you mean: 
dvankempen
Product and Topic Expert
Product and Topic Expert








philip.mugglestone from the SAP HANA Academy and the Partner Innovation Lab just uploaded a new series of hands-on video tutorials about SAP Business Technology Platform extension generators.

In this blog post you will find the videos embedded with references and additional information.

For the related blog posts, visit

For more partner-focused hands-on developer series, see

Questions? Please post as comment.

Useful? Give us a like and share on social media.

Thanks!

===

Update May 23, 2022 - added video tutorial additional services




Hands-On Video Tutorials


What You Will Learn


The SAP Business Technology Platform - Extension Generators playlist on the SAP HANA Academy YouTube channel contains 14 videos running for about 150 minutes (time of writing, new videos may be added in the future).

What you will learn

  • How to install the SAP HANA Academy CAP generator

  • How to configure the generator to create BTP business application extensions

  • How to test the app locally

  • How to build and deploy the app to the BTP Cloud Foundry environment

  • How to generate code for OData v2 (v4 is default)

  • How to configure application logging for Kibana

  • How to debug the app

  • How to generate authentication (using XSUAA)

  • How to generate authorization

  • How to generate role attributes

  • How to generate native SAP HANA Cloud artifacts (calculation view)

  • How to generate OData access to classical database schema

  • How to generate OData existing HDI container access

  • How to re-generate design time artifacts after object changes

  • How to configure additional backend services with examples of both CAP-based and regular Node.js of additional services included

  • How to interact with the SAP Analytics Cloud Tenant API using CAP or MTA


Business Value for SAP Partners


For insights and an overview of the business value for SAP partners, listen to the introduction of the SAP HANA Academy extension generators for SAP Business Technology Platform Extension Suite by Joe King.

https://youtu.be/_ZkBjxaaE7U?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Playlist


To bookmark or directly access the playlist, go to



Ingredients


To follow along, you'll need a (free) SAP BTP trial account. If you are new to the SAP SAP Business Technology Platform, consider watching the onboaring series first.

Although not required, for persistence most of the extension generator apps leverage SAP HANA Cloud. If you are new to this topic, consider watching this tutorial first.

Github Code Sample


For the code samples used in the OData Classical Schema tutorial, go to

About BTP Extension Generators


The SAP BTP extension generator uses Yeoman to scaffold a business application. This enables us to present a simple yet fully functional business application to jumpstart your app development. Whether you want to create an extension for SAP S/4HANA Cloud, SAP SuccessFactors, or build an application powered by SAP HANA Cloud, you can easily scaffold the app using the generator and adapt the app to your development.

Yeoman generators are extensively used (as extensions) in SAP Business Application Studio and you can easliy add your own. However, the IDE and generator have no dependencies. Yeoman works just a well on the command line (using the yo command) or other IDE's like Microsoft Visual Studio Code, etc.

For more information about Yeoman generators, visit



Cloud Application Programming


Tutorial


In the first video tutorial, Philip Mugglestone shows how to jumpstart a SAP Extension Suite application based on the CAP framework in the Cloud Foundry environment.

https://youtu.be/Oj0f9BSRh08?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:20 - About SAP Cloud Application Programming Model (CAP)

1:00 - Demo SAP Business Technology Platform (BTP) trial environment

1:30 - SAP Business Application Studio

2:00 - Install generator

3:00 - Run template wizard

5:45 - Code review

7:00 - Build for local development

10:00 - Build and deploy MTA project

12:00 - About extension generators


CAP - Core Functionality


Tutorial


In this video tutorial, Philip Mugglestone walks through the core functionality of the example SAP Extension Suite application based on the CAP framework and created via the jumpstart generator.

https://youtu.be/2CsKd4TphT0?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:30 - Run template wizard

1:00 - View output

1:25 - Code review

1:35 - Data model CDS

2:30 - Business logic in server module 

4:00 - API

6:00 - User interface and app router

7:20 - Multi-target application with services and modules

10:40 - Build for local development with demo

12:55 - Customising extensions


CAP - OData v2


Tutorial


In this video tutorial, Philip Mugglestone walks through how to enable OData v2 services in addition to the default of OData v4.

https://youtu.be/MMfUe1Q9xyM?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:30 - Run generator

0:55 - Code review: proxy in package.json and server.js

3:00 - Differences with actions and functions

4:10 - Run app locally 


CAP - Application Logging


Tutorial


In this video tutorial, Philip Mugglestone walks through how to enable Application Logging.

https://youtu.be/EkGDd0JARdk?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:30 - Generate app and enable application logging

1:00 - Code review: app-logging in mta.yaml

2:15 - Nodejs logging support in package.json

3:00 - Logging in catalog-service.js

4:00 - Build and deploy MTA project

4:30 - Run application

4:50 - Command cf logs

5:15 - BTP application logging service 

6:00 - Kibana dashboard


CAP - Debug


Tutorial


In this video tutorial, Philip Mugglestone walks through how to work with debug logging for both local development and testing as well as applications already deployed to BTP.

https://youtu.be/XA6S2zVpTSQ?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:30 - Debug module in package.json

0:55 - Code sample

2:40 - Run app locally

3:20 - Set debug command

4:30 - Debugging deployed apps

5:15 - Set environment variable and restage app


CAP - Security Authentication


Tutorial


In this video tutorial, Philip Mugglestone walks through how to configure authentication for both local development and testing as well as applications deployed to BTP.

https://youtu.be/ywwbPIRnMBM?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:20 - Generate app and enable authentication

0:40 - Code review

2:10 - Server module

3:10 - XSUAA service

4:05 - App router

4:45 - Run app locally

5:50 - Build and deploy MTA project

6:15 - Access server module (back-end)

6:50 - Access app router (front-end)

7:20 - Identity provider


CAP - Security Authorization


Tutorial


In this video tutorial, Philip Mugglestone walks through how to configure authorization for both local development and testing as well as applications deployed to BTP.

https://youtu.be/bRs8KPr5rYo?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:25 - Generate app and enable authorization

0:40 - Code review

1:30 - Configuration security.json with scopes and role collections

2:30 - CDS requires and restrict

3:45 - Run app locally

4:55 - Test with test.http

6:00 - App router configuration xs-app.json

6:30 - Build and deploy MTA project

6:50 - Assign role collection

7:30 - Run app


CAP - Security Attributes


Tutorial


In this video tutorial, Philip Mugglestone walks through how to configure role attributes for both local development and testing as well as applications deployed to BTP.

https://youtu.be/7LUMLDS1O58?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:25 - Generate app with role attributes

1:00 - Code review: attributes and attribute-references in xs-security.json

1:50 - Server module

3:20 - Mock users and test.http

4:00 - Run app locally

5:20 - Build and deploy MTA project

5:40 - Configure role

7:20 - Assign role collection

8:00 - Run app


CAP - Native HANA (1)


Tutorial


In this video tutorial, Philip Mugglestone walks through how to configure native SAP HANA artifacts with SAP Cloud Application Programming Model projects. Native HANA artifacts include stored procedures and calculation views.

In Part 1 Philip shows how to use the generator to scaffold an example application which is then built and deployed to the Cloud Foundry runtime and tested.

https://youtu.be/dB1PXZI3Sw8?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:30 - Business Application Studio space with full stack and calculation view editor and HANA tools

1:00 - Install SAP Partner Engineering BAS extension pack

1:50 - Install HANA Academy yeoman generator

2:10 - Generate app with SAP HANA Cloud artifacts

2:45 - Code review database and server module and MTA configuration files

7:30 - CAP documentation about Native SAP HANA

7:50 - Build and deploy MTA project

8:35 - Run app

CAP - Native HANA (2)


Tutorial


In this video tutorial, Philip Mugglestone walks through how to configure native SAP HANA artifacts with SAP Cloud Application Programming Model projects. Native HANA artifacts include stored procedures and calculation views.

In Part 2 Philip shows how to create new antive SAP HANA artifacts and test them locally before building and deploying the full application to the Cloud Foundry runtime.

https://youtu.be/w4HvHHVpSR4?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

2:10 - About gen folder

2:45 - SAP HANA tools

3:20 - Bind to HDI container and open in SAP HANA database explorer

4:30 - Create new database artifact and edit in Calculation View editor

6:35 - Deploy

7:30 - Move from gen/db/src to db/src

8:00 - Configuration file .env

8:20 - Data model

9:10 - Run app locally

10:20 - Install Cloud Foundry .env plugin

12:00 - Build and deploy MTA project

Commands


Commands used
cds build --production
cf de app-srv
CDS_ENV=production cds watch


CAP - OData Classical Schema


Tutorial


In this video tutorial, Philip Mugglestone walks through how to enable OData on all tables and views of an existing SAP HANA Cloud classical schema. Philip also shows how to access the OData service via a UI and programmatically via Postman.

https://youtu.be/8Bh7farUun8?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:40 - Prerequisites

1:20 - Allowed connections

2:00 - Open SQL Console and execute sample code [travel_OData.sql]

3:00 - Connect BAS to your BTP Cloud Foundry org and space (hack)

3:40 - Generate app with existing SAP HANA Cloud schema

5:50 - View Output

6:45 - View apps and services in SAP BTP cockpit

7:30 - Code review MTA for mta.yaml and xs-security.json

9:00 - db module

11:00 - srv module

12:00 - app module

12:30 - Build and deploy MTA project

13:00 - Assign role collection

14:00 - Run app

15:30 - Interact with OData service using Postman

16:45 - Get OAuth 2.0 token

18:00 - GET request

18:30 - POST request


CAP - Refresh OData Classical Schema


Tutorial


In this video tutorial, Philip Mugglestone walks through how to refresh a previously created OData service on all tables and views of an existing SAP HANA Cloud classical schema.

https://youtu.be/wCsEYxfOcGw?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Tutorial


0:00 - Introduction

3:15 - Run application subgenerator to update project files

6:45 - Build and deploy


CAP - OData Existing HDI Container Access


Tutorial


n this video tutorial, Philip Mugglestone walks through how to enable OData on all tables and views of an existing SAP HANA Cloud HDI container. Firstly Philip builds and deploys an example existing HDI container including hdbrole artifacts. Then he builds and deploys an application that accesses the existing HDI container via hdbgrants and hdbsynonym artIfacts.

https://www.youtube.com/watch?v=l9pwWeElmeY&list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN&index=13

Markers


0:00 - Introduction

2:00 - Deploy schema and service for HDI container

7:10 - Run SAP HANA Academy CAP generator

12:30 - Deploy app

14:15 - Add role collection

14:45 - Run app

17:00 - Undeploy app

17:30 - Undeploy HDI container

Download


Sample code


CAP - Refresh OData Existing HDI Container


Tutorial


In this video tutorial, Philip Mugglestone walks through how to refresh a previously created OData service on all tables and views of an existing SAP HANA Cloud HDI container.

https://youtu.be/b720OwaDGI8?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

2:00 - Change artefacts (design time)

3:45 - Update runtime

5:00 - Run application subgenerator to update project files

7:15 - Build and deploy


CAP - Additional Services


Tutorial


In this video tutorial, Philip Mugglestone shows how to configure additional backend services as part of a CAP project for performance, functional or scalability reasons. Both CAP-based and regular Node.js examples of additional services are configured.

https://youtu.be/Szr6ld_wpJg?list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN

Markers


0:00 - Introduction

0:50 - Start CAP generator

1:40 - Source code review

8:55 - Build and deploy 

10:45 - Recap


CAP - SAP Analytics Cloud Tenant API


Tutorial


How to configure access to the SAP Analytics Cloud Tenant API as part of a CAP project deployed to SAP BTP. Single sign-on for business users via OAuth2 SAML Bearer Assertion is covered as well as technical user authentication via OAuth2 Client Credentials.

https://www.youtube.com/watch?v=0-KyI2_qJoQ&list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN&index=32

Markers


0:00 - Introduction

0:30 - About the SAP Analytics Cloud REST API

2:20 - Add new OAuth Client in SAP Analytics Cloud

3:50 - Add Trusted Identity Provider

5:20 - HANA Academy CAP Generator for SAP Business Application Studio

6:40 - Code review

9:30 - Build and deploy 

9:50 - Add role collections using SAP BTP Cockpit

10:20 - Set Oauth Client ID and secret for the destination

11:40 - View results

12:25 - Technical user

References


For the references, see



MTA - SAP Analytics Cloud Tenant API


Tutorial


How to configure access to the SAP Analytics Cloud Tenant API as part of a multi-target application (MTA) project deployed to SAP BTP. Single sign-on for business users via OAuth2 SAML Bearer Assertion is covered as well as technical user authentication via OAuth2 Client Credentials.

https://www.youtube.com/watch?v=tcCqswhjmww&list=PLkzo92owKnVwQ-0oT78691fqvHrYXd5oN&index=38

Markers


0:00 - Introduction

0:30 - About the SAP Analytics Cloud REST API

2:25 - Add new OAuth Client in SAP Analytics Cloud

3:50 - Add Trusted Identity Provider

5:20 - HANA Academy MTA Generator for SAP Business Application Studio

7:00 - Code review

9:15 - Build and deploy 

9:35 - Set Oauth Client ID and secret for the destination

11:00 - Add role collections using SAP BTP Cockpit

11:20 - View results

12:15 - Technical user

References


For the references, see


Share and Connect


Questions? Please post as comment.

Useful? Give us a like and share on social media.

Thanks!

If you would like to receive updates, connect with me on

For the author page of SAP PRESS, visit







Over the years, for the SAP HANA Academy, SAP’s Partner Innovation Lab, and à titre personnel, I have written a little over 300 posts here for the SAP Community. Some articles only reached a few readers. Others attracted quite a few more.For your reading pleasure and convenience, here is a curated list of posts which somehow managed to pass the 10k-view mile stone and, as sign of current interest, still tickle the counters each month.


11 Comments