Cloud Foundry
BTP & Integrationbeginner

Understanding Cloud Foundry Organizations, Spaces, and Entitlements on SAP BTP

Learn why SAP BTP uses Cloud Foundry as a runtime, how orgs and spaces map to subaccounts, and how entitlements and quotas control what you can deploy.

Explanation

SAP BTP offers multiple runtimes, and Cloud Foundry (CF) is the original and still widely used environment for deploying custom applications, integration flows backing services, and extension logic. Understanding CF's structural model is the foundation for everything else you do on BTP, because almost every deployment decision, from service binding to scaling to security, happens inside this hierarchy. At the top of the BTP hierarchy sits the global account, which is subdivided into subaccounts. When you enable the Cloud Foundry environment on a subaccount, BTP automatically creates exactly one Cloud Foundry organization (org) tied to that subaccount. This is a one-to-one relationship: one subaccount equals one CF org. Inside that org, you create one or more spaces, which are logical partitions used to separate applications by purpose, such as dev, test, or by team ownership. Spaces are where you actually push applications, create service instances, and bind them together. Every org has a quota plan that limits total memory, number of routes, number of services, and number of app instances available across all its spaces. This quota is consumed from the entitlements assigned to the subaccount in the BTP cockpit. Entitlements are the mechanism by which a global account administrator allocates capacity (e.g., a certain amount of memory or a specific number of service plan instances) from the global account's contract down to individual subaccounts. If you try to push an application or create a service instance that exceeds the subaccount's entitled quota, the operation fails, and troubleshooting must start with checking entitlements in the cockpit, not just the CF CLI output. Access control in CF is layered. Org-level roles (Org Manager, Org Auditor, Org Billing Manager) control administrative capabilities across the whole org, while space-level roles (Space Developer, Space Manager, Space Auditor) control who can deploy, view, or manage resources within a specific space. Most day-to-day consultants and developers only need Space Developer to push apps and manage service bindings. These roles are assigned either directly in the CF space (via CLI or cockpit) or, in more mature setups, through role collections tied to your platform identity provider. To actually interact with CF, you use the `cf` command-line interface, which you install locally and then authenticate against your specific CF API endpoint (each BTP region has its own API endpoint URL, such as one for Europe (Frankfurt) or the US). Getting the endpoint wrong is one of the most common first-day mistakes because BTP is multi-region, and an org that exists in one region's CF landscape is invisible from another region's API endpoint. Understanding this model matters practically: architects use org/space separation to isolate environments and enforce least-privilege access; developers use spaces to avoid naming collisions and to test in isolation before promoting to a shared space; and support teams use org/space boundaries to reason about blast radius when an application misbehaves. Getting this mental model right before writing a single line of application code prevents a large share of early configuration confusion on BTP.

Code example

ABAP Code
# Typical first-time CF CLI workflow on SAP BTP # 1. Point the CLI at your region's API endpoint (region-specific!)cf api https://api.cf.eu10.hana.ondemand.com # 2. Log in with your BTP platform usercf login # 3. List orgs you have access to (usually one org per subaccount)cf orgs # 4. Target the org and space you will work incf target -o my-company-dev-org -s dev # 5. Confirm current target context before doing anything destructivecf target # 6. List current quota usage for the targeted orgcf org my-company-dev-org

Real project scenario

A new integration consultant joins a project and is given BTP cockpit access but cannot push a simple test application. After 30 minutes of confusion, the lead discovers the consultant was targeting the API endpoint for a different region than the one where the customer's subaccount actually lives. Once the correct regional endpoint and org/space were targeted, the push succeeded immediately. This kind of region mismatch is extremely common on multi-region BTP global accounts with subaccounts spread across Europe, US, and Asia-Pacific data centers.

Common mistakes

โ€ข Targeting the wrong regional CF API endpoint, leading to 'org not found' errors even though the org clearly exists in the cockpit โ€ข Assuming entitlements are unlimited and only discovering quota exhaustion when a push fails in production โ€ข Giving broad Org Manager access to developers who only need Space Developer, violating least-privilege principles โ€ข Confusing subaccount-level role collections (used for cockpit and platform services) with CF org/space roles (used for CLI-level app operations) โ€ข Not documenting which space (dev/test/prod) maps to which purpose, causing accidental deployments to the wrong environment

Best practices

โ€ข Always confirm the targeted API endpoint, org, and space before pushing or deleting anything, especially in shared environments โ€ข Use separate spaces for dev, test, and production rather than relying on naming conventions within a single space โ€ข Assign the minimum necessary role (typically Space Developer) to hands-on developers and reserve Org Manager for platform administrators โ€ข Review entitlements proactively during project planning so quota exhaustion does not block a go-live โ€ข Maintain a simple internal map of subaccount-to-org-to-space naming so new team members can orient quickly

Interview angle

Interviewers often ask candidates to explain the relationship between BTP subaccounts, CF orgs, and CF spaces, and to describe how entitlements constrain deployments. A strong answer distinguishes global account level entitlement allocation from org-level quota consumption, and explains the practical difference between org roles and space roles rather than treating them as interchangeable.