├── .lycheeignore
├── src
└── api
│ ├── .deployment
│ ├── tsconfig.build.json
│ ├── nest-cli.json
│ ├── service-specifications
│ └── config.json
│ ├── manifest.yaml
│ ├── rome.json
│ ├── src
│ ├── app.controller.ts
│ ├── main.ts
│ ├── app.module.ts
│ ├── public
│ │ ├── stylesheets
│ │ │ └── style.css
│ │ └── github-logo.svg
│ ├── business-partner
│ │ ├── business-partner.service.spec.ts
│ │ └── business-partner.controller.spec.ts
│ ├── app.controller.spec.ts
│ ├── views
│ │ ├── bupa.pug
│ │ └── index.pug
│ └── app.service.ts
│ ├── tsconfig.json
│ ├── services
│ └── business-partner-service-1
│ │ ├── CustomerText.ts
│ │ ├── SupplierText.ts
│ │ ├── CustomerRequestBuilder.ts
│ │ ├── SupplierRequestBuilder.ts
│ │ ├── CustomerCompanyText.ts
│ │ ├── SupplierCompanyText.ts
│ │ ├── BuPaIndustry.ts
│ │ ├── BusinessPartnerRole.ts
│ │ ├── SupplierPurchasingOrgText.ts
│ │ ├── BusinessPartnerTaxNumber.ts
│ │ ├── BpContactToAddressRequestBuilder.ts
│ │ ├── BusinessPartnerRequestBuilder.ts
│ │ ├── CustomerSalesAreaText.ts
│ │ ├── AddressEmailAddress.ts
│ │ ├── BuPaAddressUsage.ts
│ │ ├── CustomerCompanyRequestBuilder.ts
│ │ ├── SupplierCompanyRequestBuilder.ts
│ │ ├── CustomerSalesAreaTax.ts
│ │ ├── BusinessPartnerRoleRequestBuilder.ts
│ │ ├── BpContactToFuncAndDeptRequestBuilder.ts
│ │ ├── SupplierPurchasingOrgRequestBuilder.ts
│ │ ├── CustomerTaxGrouping.ts
│ │ ├── CustomerSalesAreaRequestBuilder.ts
│ │ ├── AddressHomePageUrl.ts
│ │ └── AddressFaxNumber.ts
│ └── package.json
├── package.json
├── .gitattributes
├── .gitignore
├── assets
├── drawings.pptx
├── bupa-get-vsc-rest.png
├── apim-backoff-delay.png
├── bupa-create-vsc-rest.png
├── bupa-delete-vsc-rest.png
├── bupa-update-vsc-rest.png
└── project-overview-azd-style.png
├── infra-terraform
├── modules
│ ├── loganalytics
│ │ ├── loganalytics_output.tf
│ │ ├── loganalytics_variables.tf
│ │ └── loganalytics.tf
│ ├── apim-api
│ │ ├── apim-api_output.tf
│ │ ├── apim-api_variables.tf
│ │ └── apim-api.tf
│ ├── appserviceplan
│ │ ├── appserviceplan_output.tf
│ │ ├── appserviceplan_variables.tf
│ │ └── appserviceplan.tf
│ ├── keyvault
│ │ ├── keyvault_output.tf
│ │ ├── keyvault_variables.tf
│ │ └── keyvault.tf
│ ├── apim
│ │ ├── apim_output.tf
│ │ ├── apim_variables.tf
│ │ └── apim.tf
│ ├── cosmos
│ │ ├── cosmos_output.tf
│ │ ├── cosmos_variables.tf
│ │ └── cosmos.tf
│ ├── appservicenode
│ │ ├── appservicenode_output.tf
│ │ ├── appservicenode_variables.tf
│ │ └── appservicenode.tf
│ └── applicationinsights
│ │ ├── applicationinsights_output.tf
│ │ └── applicationinsights_variables.tf
├── modules_local
│ ├── apim-api
│ │ ├── apim-api_output.tf
│ │ ├── apim-api_variables.tf
│ │ └── apim-api.tf
│ └── appservicenode
│ │ ├── appservicenode_output.tf
│ │ ├── appservicenode.tf
│ │ └── appservicenode_variables.tf
├── main.tfvars.json
├── output.tf
├── provider.tf
└── variables.tf
├── CHANGELOG.md
├── test
├── jest-e2e.json
└── app.e2e-spec.ts
├── templates
├── azuredeploy.parameters.json
└── .env
├── .vscode
├── settings.json
└── launch.json
├── infra
├── main.parameters.json
├── core
│ ├── testing
│ │ └── loadtesting.bicep
│ ├── host
│ │ ├── staticwebapp.bicep
│ │ ├── appserviceplan.bicep
│ │ ├── appservice-appsettings.bicep
│ │ ├── aks-agent-pool.bicep
│ │ ├── container-apps-environment.bicep
│ │ ├── container-apps.bicep
│ │ └── functions.bicep
│ ├── monitor
│ │ ├── loganalytics.bicep
│ │ ├── applicationinsights.bicep
│ │ └── monitoring.bicep
│ ├── database
│ │ ├── cosmos
│ │ │ ├── sql
│ │ │ │ ├── cosmos-sql-role-assign.bicep
│ │ │ │ ├── cosmos-sql-account.bicep
│ │ │ │ ├── cosmos-sql-role-def.bicep
│ │ │ │ └── cosmos-sql-db.bicep
│ │ │ ├── mongo
│ │ │ │ ├── cosmos-mongo-account.bicep
│ │ │ │ └── cosmos-mongo-db.bicep
│ │ │ └── cosmos-account.bicep
│ │ ├── mysql
│ │ │ └── flexibleserver.bicep
│ │ └── postgresql
│ │ │ └── flexibleserver.bicep
│ ├── security
│ │ ├── keyvault-access.bicep
│ │ ├── role.bicep
│ │ ├── keyvault.bicep
│ │ ├── aks-managed-cluster-access.bicep
│ │ ├── registry-access.bicep
│ │ ├── configstore-access.bicep
│ │ └── keyvault-secret.bicep
│ ├── networking
│ │ ├── cdn-profile.bicep
│ │ ├── cdn.bicep
│ │ └── cdn-endpoint.bicep
│ ├── config
│ │ └── configstore.bicep
│ ├── ai
│ │ └── cognitiveservices.bicep
│ ├── search
│ │ └── search-services.bicep
│ └── storage
│ │ └── storage-account.bicep
└── app
│ ├── api.bicep
│ └── apim-api-policy.xml
├── infra-btpsa
├── parameters.json
└── usecase.json
├── .github
├── CODE_OF_CONDUCT.md
├── dependabot.yml
├── PULL_REQUEST_TEMPLATE.md
├── workflows
│ ├── links-watcher.yml
│ ├── azure-dev.yml
│ └── codeql.yml
└── ISSUE_TEMPLATE
│ ├── feature_request.yml
│ └── bug_report.yml
├── workspaces
├── azd-terraform.code-workspace
├── azd-bicep.code-workspace
└── btpsa.code-workspace
├── LICENSE.md
├── sample-http-requests
└── business-partner-requests.http
├── .devcontainer
├── azd-terraform
│ └── devcontainer.json
├── devcontainer.json
├── azd-bicep
│ └── devcontainer.json
└── btpsa
│ └── devcontainer.json
├── documentation
├── DEPLOYMENT-VSCODE.md
└── ADDITIONAL-RESOURCES.md
├── azure.yaml
├── hooks
└── deleteAppRegistrations.ps1
└── .azdo
└── pipelines
└── azure-dev.yml
/ .lycheeignore:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/src/api/.deployment:
--------------------------------------------------------------------------------
1 | [config]
2 | SCM_DO_BUILD_DURING_DEPLOYMENT=true
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "dependencies": {
3 | "@sap-cloud-sdk/util": "^3.25.0"
4 | }
5 | }
6 |
--------------------------------------------------------------------------------
/.gitattributes:
--------------------------------------------------------------------------------
1 | * text=auto eol=lf
2 | *.{cmd,[cC][mM][dD]} text eol=crlf
3 | *.{bat,[bB][aA][tT]} text eol=crlf
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | .azure
2 | node_modules
3 | dist
4 | infra-terraform/.terraform.lock.hcl
5 | .$*.bkp
6 | .$*.dtmp
7 |
--------------------------------------------------------------------------------
/assets/drawings.pptx:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/app-service-javascript-sap-cloud-sdk-quickstart/HEAD/assets/drawings.pptx
--------------------------------------------------------------------------------
/src/api/tsconfig.build.json:
--------------------------------------------------------------------------------
1 | {
2 | "extends": "./tsconfig.json",
3 | "exclude": ["node_modules", "test", "dist", "**/*spec.ts"]
4 | }
5 |
--------------------------------------------------------------------------------
/assets/bupa-get-vsc-rest.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/app-service-javascript-sap-cloud-sdk-quickstart/HEAD/assets/bupa-get-vsc-rest.png
--------------------------------------------------------------------------------
/assets/apim-backoff-delay.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/app-service-javascript-sap-cloud-sdk-quickstart/HEAD/assets/apim-backoff-delay.png
--------------------------------------------------------------------------------
/assets/bupa-create-vsc-rest.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/app-service-javascript-sap-cloud-sdk-quickstart/HEAD/assets/bupa-create-vsc-rest.png
--------------------------------------------------------------------------------
/assets/bupa-delete-vsc-rest.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/app-service-javascript-sap-cloud-sdk-quickstart/HEAD/assets/bupa-delete-vsc-rest.png
--------------------------------------------------------------------------------
/assets/bupa-update-vsc-rest.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/app-service-javascript-sap-cloud-sdk-quickstart/HEAD/assets/bupa-update-vsc-rest.png
--------------------------------------------------------------------------------
/infra-terraform/modules/loganalytics/loganalytics_output.tf:
--------------------------------------------------------------------------------
1 | output "LOGANALYTICS_WORKSPACE_ID" {
2 | value = azurerm_log_analytics_workspace.workspace.id
3 | }
--------------------------------------------------------------------------------
/src/api/nest-cli.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://json.schemastore.org/nest-cli",
3 | "collection": "@nestjs/schematics",
4 | "sourceRoot": "src"
5 | }
6 |
--------------------------------------------------------------------------------
/infra-terraform/modules/apim-api/apim-api_output.tf:
--------------------------------------------------------------------------------
1 | output "SERVICE_API_URI" {
2 | value = "${data.azurerm_api_management.apim.gateway_url}/${var.api_path}"
3 | }
4 |
--------------------------------------------------------------------------------
/infra-terraform/modules/appserviceplan/appserviceplan_output.tf:
--------------------------------------------------------------------------------
1 | output "APPSERVICE_PLAN_ID" {
2 | value = azurerm_service_plan.plan.id
3 | sensitive = true
4 | }
--------------------------------------------------------------------------------
/infra-terraform/modules/keyvault/keyvault_output.tf:
--------------------------------------------------------------------------------
1 | output "AZURE_KEY_VAULT_ENDPOINT" {
2 | value = azurerm_key_vault.kv.vault_uri
3 | sensitive = true
4 | }
--------------------------------------------------------------------------------
/assets/project-overview-azd-style.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/Azure-Samples/app-service-javascript-sap-cloud-sdk-quickstart/HEAD/assets/project-overview-azd-style.png
--------------------------------------------------------------------------------
/infra-terraform/modules_local/apim-api/apim-api_output.tf:
--------------------------------------------------------------------------------
1 | output "SERVICE_API_URI" {
2 | value = "${data.azurerm_api_management.apim.gateway_url}/${var.api_path}"
3 | }
4 |
--------------------------------------------------------------------------------
/infra-terraform/main.tfvars.json:
--------------------------------------------------------------------------------
1 | {
2 | "location": "${AZURE_LOCATION}",
3 | "environment_name": "${AZURE_ENV_NAME}",
4 | "principal_id": "${AZURE_PRINCIPAL_ID}"
5 | }
6 |
--------------------------------------------------------------------------------
/CHANGELOG.md:
--------------------------------------------------------------------------------
1 | ## [project-title] Changelog
2 |
3 |
4 | # x.y.z (yyyy-mm-dd)
5 |
6 | *Features*
7 | * ...
8 |
9 | *Bug Fixes*
10 | * ...
11 |
12 | *Breaking Changes*
13 | * ...
14 |
--------------------------------------------------------------------------------
/infra-terraform/modules/apim/apim_output.tf:
--------------------------------------------------------------------------------
1 | output "APIM_SERVICE_NAME" {
2 | value = azurerm_api_management.apim.name
3 | }
4 |
5 | output "API_MANAGEMENT_LOGGER_ID" {
6 | value = azurerm_api_management_logger.logger.id
7 | }
8 |
--------------------------------------------------------------------------------
/test/jest-e2e.json:
--------------------------------------------------------------------------------
1 | {
2 | "moduleFileExtensions": ["js", "json", "ts"],
3 | "rootDir": ".",
4 | "testEnvironment": "node",
5 | "testRegex": ".e2e-spec.ts$",
6 | "transform": {
7 | "^.+\\.(t|j)s$": "ts-jest"
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/templates/azuredeploy.parameters.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#",
3 | "contentVersion": "1.0.0.0",
4 | "parameters": {
5 | "webAppName": {
6 | "value": "GEN-UNIQUE"
7 | }
8 | }
9 | }
--------------------------------------------------------------------------------
/.vscode/settings.json:
--------------------------------------------------------------------------------
1 | {
2 | "appService.zipIgnorePattern": [
3 | "node_modules{,/**}",
4 | ".vscode{,/**}",
5 | "img{,/**}",
6 | "templates{,/**}",
7 | ".env"
8 | ],
9 | "appService.deploySubpath": "src/api"
10 | }
--------------------------------------------------------------------------------
/src/api/service-specifications/config.json:
--------------------------------------------------------------------------------
1 | {
2 | "service-specifications/ZAPI_BUSINESS_PARTNER.edmx": {
3 | "packageName": "business-partner-service-1",
4 | "directoryName": "business-partner-service-1",
5 | "basePath": "/sap/opu/odata/sap/API_BUSINESS_PARTNER"
6 | }
7 | }
8 |
--------------------------------------------------------------------------------
/infra-terraform/modules/cosmos/cosmos_output.tf:
--------------------------------------------------------------------------------
1 | output "AZURE_COSMOS_CONNECTION_STRING" {
2 | value = azurerm_cosmosdb_account.db.connection_strings[0]
3 | sensitive = true
4 | }
5 |
6 | output "AZURE_COSMOS_DATABASE_NAME" {
7 | value = azurerm_cosmosdb_mongo_database.mongodb.name
8 | }
--------------------------------------------------------------------------------
/src/api/manifest.yaml:
--------------------------------------------------------------------------------
1 | applications:
2 | - name: cloudsdkapp
3 | path: .
4 | buildpacks:
5 | - nodejs_buildpack
6 | memory: 1G
7 | command: npm run start:prod
8 | random-route: true
9 | build-parameters:
10 | builder: custom
11 | commands:
12 | - npm run build
--------------------------------------------------------------------------------
/infra-terraform/modules/appservicenode/appservicenode_output.tf:
--------------------------------------------------------------------------------
1 | output "URI" {
2 | value = "https://${azurerm_linux_web_app.web.default_hostname}"
3 | }
4 |
5 | output "IDENTITY_PRINCIPAL_ID" {
6 | value = length(azurerm_linux_web_app.web.identity) == 0 ? "" : azurerm_linux_web_app.web.identity.0.principal_id
7 | sensitive = true
8 | }
--------------------------------------------------------------------------------
/infra-terraform/modules_local/appservicenode/appservicenode_output.tf:
--------------------------------------------------------------------------------
1 | output "URI" {
2 | value = "https://${azurerm_linux_web_app.web.default_hostname}"
3 | }
4 |
5 | output "IDENTITY_PRINCIPAL_ID" {
6 | value = length(azurerm_linux_web_app.web.identity) == 0 ? "" : azurerm_linux_web_app.web.identity.0.principal_id
7 | sensitive = true
8 | }
--------------------------------------------------------------------------------
/infra/main.parameters.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentParameters.json#",
3 | "contentVersion": "1.0.0.0",
4 | "parameters": {
5 | "environmentName": {
6 | "value": "${AZURE_ENV_NAME}"
7 | },
8 | "location": {
9 | "value": "${AZURE_LOCATION}"
10 | },
11 | "principalId": {
12 | "value": "${AZURE_PRINCIPAL_ID}"
13 | }
14 | }
15 | }
--------------------------------------------------------------------------------
/infra/core/testing/loadtesting.bicep:
--------------------------------------------------------------------------------
1 | param name string
2 | param location string = resourceGroup().location
3 | param managedIdentity bool = false
4 | param tags object = {}
5 |
6 | resource loadTest 'Microsoft.LoadTestService/loadTests@2022-12-01' = {
7 | name: name
8 | location: location
9 | tags: tags
10 | identity: { type: managedIdentity ? 'SystemAssigned' : 'None' }
11 | properties: {
12 | }
13 | }
14 |
15 | output loadTestingName string = loadTest.name
16 |
--------------------------------------------------------------------------------
/infra-btpsa/parameters.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "https://raw.githubusercontent.com/SAP-samples/btp-setup-automator/main/libs/btpsa-parameters.json",
3 | "usecasefile": "usecase.json",
4 | "region": "eu20",
5 | "globalaccount": "ID of your Global Account",
6 | "myemail": "Enter your email address here",
7 | "loginmethod": "basicAuthentication",
8 | "subaccountname": "SAP-Cloud-SDK-Quickstart",
9 | "cfspacename": "development",
10 | "prunesubaccount": false
11 | }
--------------------------------------------------------------------------------
/.github/CODE_OF_CONDUCT.md:
--------------------------------------------------------------------------------
1 | # Microsoft Open Source Code of Conduct
2 |
3 | This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
4 |
5 | Resources:
6 |
7 | - [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/)
8 | - [Microsoft Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/)
9 | - Contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with questions or concerns
10 |
--------------------------------------------------------------------------------
/.vscode/launch.json:
--------------------------------------------------------------------------------
1 | {
2 | // Use IntelliSense to learn about possible attributes.
3 | // Hover to view descriptions of existing attributes.
4 | // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
5 | "version": "0.2.0",
6 | "configurations": [
7 | {
8 | "type": "node-terminal",
9 | "name": "Run npm start:dev",
10 | "request": "launch",
11 | "command": "npm run start:dev",
12 | "cwd": "${workspaceFolder}/src/api"
13 | }
14 | ]
15 | }
--------------------------------------------------------------------------------
/src/api/rome.json:
--------------------------------------------------------------------------------
1 | {
2 | "$schema": "./node_modules/rome/configuration_schema.json",
3 | "files": {
4 | "ignore": [
5 | "./dist/*",
6 | "./node_modules/*",
7 | "./services/*"
8 | ]
9 | },
10 | "linter": {
11 | "enabled": true,
12 | "rules": {
13 | "recommended": true
14 | }
15 | },
16 | "formatter": {
17 | "enabled": true,
18 | "formatWithErrors": false,
19 | "indentStyle": "tab",
20 | "indentSize": 2,
21 | "lineWidth": 80,
22 | "ignore": []
23 | }
24 | }
--------------------------------------------------------------------------------
/.github/dependabot.yml:
--------------------------------------------------------------------------------
1 | version: 2
2 | updates:
3 | - package-ecosystem: "github-actions"
4 | directory: "/"
5 | schedule:
6 | # Check for updates to GitHub Actions once a week on Monday
7 | interval: "weekly"
8 | day: "monday"
9 | - package-ecosystem: "npm"
10 | directory: "/"
11 | schedule:
12 | interval: "weekly"
13 | day: "monday"
14 | - package-ecosystem: "devcontainers"
15 | directory: "/"
16 | schedule:
17 | interval: "weekly"
18 | day: "monday"
19 |
--------------------------------------------------------------------------------
/src/api/src/app.controller.ts:
--------------------------------------------------------------------------------
1 | import { Controller, Get, Render } from "@nestjs/common";
2 | import { AppService } from "./app.service";
3 |
4 | @Controller()
5 | export class AppController {
6 | constructor(private readonly appService: AppService) {}
7 |
8 | @Get()
9 | @Render('index')
10 | async getHello(): Promise