| name | btp-business-application-studio |
| description | SAP Business Application Studio (BAS) — dev spaces, CAP project creation, Fiori tools, debugger setup, hybrid testing, deployment workflows, source control. Use when working in BAS, creating dev spaces, configuring extensions, or troubleshooting BAS connectivity.
|
| trigger | ["create BAS dev space","create CAP project in BAS","debug CAP application in BAS","deploy from BAS to BTP","configure BAS extensions","hybrid testing in BAS"] |
SAP Business Application Studio (BAS)
Cloud IDE on SAP BTP for CAP, Fiori, and full-stack development. Browser-based, no local install needed.
Prerequisites
- SAP BTP subaccount with SAP Business Application Studio entitlement
- Subscribed to BAS app (BTP Cockpit → Service Marketplace → Subscribe)
- Space Quota with sufficient memory (min 4 GB for dev space)
- Cloud Foundry CLI installed locally for
cf commands outside BAS
- GitHub/GitLab account or SAP Git repository for source control
Dev Space Types
| Type | Key Extensions | Best For |
|---|
| Full Stack Cloud Application | CAP, CDS, Fiori tools, MTA | CAP + Fiori apps |
| SAP Fiori | Fiori tools, UI5 Adaptation | Freestyle UI5, adaptation |
| SAP HANA Native | HANA tools, DB Explorer, HDI | HANA DB artifacts |
| Basic | None (manual install) | Custom setup, non-SAP |
Steps
1. Create a Dev Space
- Open BTP Cockpit → Service Marketplace → SAP Business Application Studio → Go to Application
- Click Create Dev Space → Enter name
- Select type: Full Stack Cloud Application (for CAP + Fiori)
- Optionally add extensions (defaults are sufficient for most workflows)
- Click Create → wait ~2 min → status shows RUNNING
- Click dev space name to open the IDE in browser
2. Create a CAP Project
cd /home/user/projects
cds init my-app --add java,nodejs,mta,fiori,sample
cd my-app
npm install
3. Clone an Existing Project
cd /home/user/projects
git clone https://github.com/myorg/my-cap-app.git
cd my-cap-app
npm install
4. Hybrid Testing with BTP Services
Bind local CAP runtime to BTP-backed services (HDI, XSUAA, destination) for realistic testing:
cds bind -2 my-hdi-container,my-xsuaa
cds watch --profile hybrid
curl http://localhost:4004/odata/v4/catalog/Books
5. Set Up the Debugger
- Open the
.js or .ts handler file in BAS editor
- Click the gutter next to a line number to set a breakpoint (red dot)
- Press
F5 → select debug configuration: CDS with Node.js
- Debugger pauses at breakpoint — use:
F10: Step Over
F11: Step Into
Shift+F11: Step Out
F5: Continue
- Watch variables in the left panel; use Console for expressions
6. Build and Deploy
cds build
mbt build
cf login -a https://api.cf.us10.hana.ondemand.com -o <org> -s <space>
cf deploy mta_archives/my-app_1.0.0.mtar
git add -A && git commit -m "feat: initial CAP app"
git push origin main
Pitfalls
| Cause | Solution |
|---|
| Dev space stopped unexpectedly | Dev spaces auto-stop after 30 min idle. In BAS launcher, click Start to resume. Work is preserved. |
cds bind fails with "service not found" | Service instances must exist in the current CF space. Run cf services to verify. Create missing instances with cf create-service. |
| Large node_modules exceeds 10 GB limit | Dev spaces have 10 GB storage. Run npm prune --production or delete .cache/ dir. Use npm ci instead of npm install for deterministic builds. |
| Only one dev space running | Free-tier subaccounts allow only 1 running dev space. Stop others before starting a new one. |
| Extension not found in marketplace | BAS uses the Open VSX Registry, not the VS Code Marketplace. Install custom extensions from .vsix files via Extensions → ... → Install from VSIX. |
mbt build fails — Makefile not found | Run cds add mta first to generate the mta.yaml and Makefile. Ensure mbt CLI is installed: npm install -g mbt. |
| Debugger won't attach | Ensure cds watch is not already running on the same port. Stop it, then start via F5 debug config. Check .vscode/launch.json exists. |
Verification
cds compile srv/ -2 sql 2>&1 | head -5
curl -s http://localhost:4004/odata/v4/catalog/$metadata | head -3
ls -la mta_archives/*.mtar
cf apps
curl -s https://my-app.cfapps.<region>.hana.ondemand.com/odata/v4/catalog/$metadata | head -3
git log --oneline -3
git status
Checklist: