OData system notes - SAP and Microsoft
S/4HANA, SuccessFactors, Dynamics 365 and Business Central - what to put in the connection's form for each platform.
The protocol is the same everywhere, yet each platform has its own service root layout, auth expectations and quirks. The notes below list what to put in the connection's form for each of the four big OData platforms.
SAP S/4HANA
S/4HANA exposes classic Gateway services over OData V2 and newer ones over V4. SAP systems also have their own connection type and a dedicated chapter - the notes below apply to plain OData connections pointed at S/4HANA.
- Address:
https://host:port/sap/opu/odata/sap/API_BUSINESS_PARTNER(V2) orhttps://host:port/sap/opu/odata4/sap/...(V4) - OData version: match the service -
2.0for/sap/opu/odata/,4.0for/sap/opu/odata4/ - Auth type: Basic with a technical user, or OAuth2 in BTP-fronted setups
- Needs CSRF token: enable it - Gateway requires X-CSRF-Token for every write
- The
sap-clientparameter, when needed, travels through the custom query option:
SAP SuccessFactors
SuccessFactors speaks OData V2 and its entity model is large - User, EmpJob, PerPersonal and hundreds of others.
- Address:
https://apisalesdemo2.successfactors.eu/odata/v2- the host depends on the data center - OData version:
2.0 - Auth type: OAuth2 - SuccessFactors issues tokens through its own token endpoint,
https://<host>/oauth/token - Paging: SuccessFactors caps pages and returns
__nextlinks - use .iter and the client follows them
Microsoft Dynamics 365 Finance and Operations
- Address:
https://<environment>.operations.dynamics.com/data - OData version:
4.0 - Auth type: OAuth2 against Microsoft Entra ID
- Token URL:
https://login.microsoftonline.com/{tenant_id}/oauth2/v2.0/token - Tenant ID: your Entra ID tenant
- Scopes:
https://<environment>.operations.dynamics.com/.default
- Token URL:
- Entity names are plural and case-sensitive, e.g.
CustomersV3, and most entity sets use composite keys that includedataAreaId:
Microsoft Business Central
Business Central publishes its standard API under version-numbered paths and everything lives inside a company.
- Address:
https://api.businesscentral.dynamics.com/v2.0/<tenant>/<environment>/api/v2.0 - OData version:
4.0 - Auth type: OAuth2 against Microsoft Entra ID with the
https://api.businesscentral.dynamics.com/.defaultscope - sandboxes also accept Basic with web-service access keys - Companies come first - read the
companiesentity set once, then address everything else through the company's ID:
companies = conn.read('companies')
company_id = companies[0]['id']
customers = conn.read(f'companies({company_id})/customers', top=10)
- Business Central enforces optimistic concurrency - pass the
@odata.etagan entity came with when updating or deleting it.