Genome declaration
language: sap-btp
solution_name: MyProcurementSuite
btp_services:
- service: xsuaa
plan: application
description: Authentication & authorisation
config:
xsappname: myproc-xsuaa
tenant-mode: dedicated
- service: hana
plan: hdi-shared
description: HANA Cloud HDI container
- service: destination
plan: lite
description: Destination service for RFC/OData connectivity
- service: connectivity
plan: lite
description: Cloud Connector for on-premise RFC
- service: integration
plan: api
description: SAP Integration Suite for iFlow orchestration
What gets generated
sap-btp/
├── mta.yaml # MTA descriptor: approuter + srv + all service resources
├── xs-security.json # XSUAA: scopes, role templates, role collections
├── package.json # @sap/cds root + tooling
├── approuter/
│ └── xs-app.json # Approuter routing (present when xsuaa is in services)
├── terraform/
│ └── btp.tf # Terraform SAP/btp provider: entitlements + service instances
├── scripts/
│ └── btpctl_setup.sh # BTP CLI alternative to Terraform
└── README.md # Deployment checklist (deploy in 30 min, customize 2–3 days)
MTA — all services declared, approuter only when XSUAA present
The MTA generator conditionally includes the approuter module only when xsuaa is in your btp_services. If you're not using XSUAA, you don't get an approuter. This means the MTA is minimal — no orphan resources.
Terraform — SAP/btp provider, entitlements + instances
resource "btp_subaccount_entitlement" "myproc_xsuaa" {
subaccount_id = var.btp_subaccount_id
service_name = "xsuaa"
plan_name = "application"
}
resource "btp_subaccount_service_instance" "myproc_xsuaa" {
subaccount_id = var.btp_subaccount_id
serviceplan_id = btp_subaccount_entitlement.myproc_xsuaa.id
name = "myproc-xsuaa"
parameters = jsonencode({"xsappname": "myproc-xsuaa", "tenant-mode": "dedicated"})
depends_on = [btp_subaccount_entitlement.myproc_xsuaa]
}
One Terraform resource block per service, in the correct order (entitlement before instance, depends_on wired), using the official SAP/btp Terraform provider.
BTP CLI script — alternative for teams that prefer btp CLI over Terraform
btp create services/instance \
--subaccount "${BTP_SUBACCOUNT_GUID}" \
--offering-name "xsuaa" \
--plan-name "application" \
--name "myproc-xsuaa"
One command per service in the correct order. Reads BTP_SUBACCOUNT_GUID from the environment — no hardcoded GUIDs.
Deployment checklist (from generated README)
[ ] Set BTP_SUBACCOUNT_GUID and CF_SPACE environment variables
[ ] Run btpctl_setup.sh OR terraform apply
[ ] cf login -a <API_ENDPOINT>
[ ] cf target -o <ORG> -s <SPACE>
[ ] mbt build && cf deploy mta_archives/*.mtar
[ ] Assign role collections in BTP Cockpit
Everything before "Assign role collections" can be scripted. The only manual step is the BTP Cockpit role assignment — which is intentional (you want a human to confirm who gets what access in production).
Supported BTP services
Any BTP managed service can be declared. Common examples:
| Service | Plan | Use |
|---------|------|-----|
| xsuaa | application | Authentication (XSUAA JWT) |
| hana | hdi-shared | HANA Cloud HDI container |
| destination | lite | OData/RFC destination catalogue |
| connectivity | lite | Cloud Connector (on-premise) |
| integration | api | SAP Integration Suite |
| ai-core | extended | SAP AI Core (LLM / ML) |
| build-apps | standard | SAP Build Apps (low-code UI) |
| enterprise-messaging | dev | SAP Event Mesh |
Internal links
- SAP CAP integration for the application-layer generator
- SAP RISE migration use case for migration readiness
CTA
Try it — free plan, no credit card. archiet.com.
Add five btp_services lines to your genome. Generate. Open the Terraform file and the MTA descriptor. Check whether the service names, plan names, and dependencies are the shape your BTP team would approve.