SAP BTP

Business Technology Platform Blog Posts

开发Spring-boot应用程序,连接菜鸟物流平台Api并将其部署到BTP Cloud Foundry

目前,我正在准备一个S/4 Hana Cloud的SPA并排扩展做。在这个场景中,来自S/4 Hana云的出库创建事件将触发一个SPA流程,然后SPA流程将使用行动调用物流Api来创建快递订单并保存相关信息。POC的第一步是调用物流Api。我位于中国上海,菜鸟物流平台非常著名,对开发商非常友好。通过菜鸟平台Api,我们可以与DHL、Fedex、EMS、UPS等快递公司进行业务往来。被支持的快递公司处于中文链接中。 事实上,我试过其他快递公司的API,他们需要我提供公司信息和信用卡,这对于我作为解决方案咨询的顾问来说不太好,因为我只需要进行解决方案的原型验证。 今天,我想演示如何生成一个Spring-boot应用程序,并将其部署在BTP Cloud Foundry中,以调用CaiNiao物流平台API,该应用可以直接从SPA Action中使用。然后你可能会问我们为什么不直接调用菜鸟物流Api。究其原因,是菜鸟物流平台API有一个比较复杂的签名逻辑。我们不能在SPA  Action或CPI中直接调用。我认为我们可以在CPI中创建一个Adater,也许我会在不久的将来对此进行探索。   前提条件: Java jdk1.8 安装了 Maven 比如版本3.9.2安装了 Cloud Foundry Command Line Interface 安装了 步骤1 用手机在菜鸟物流平台API注册账户,我们会得到appId和appSecret,它们将在Spring-boot应用程序中使用。 步骤2,使用以下命令生成Spring-boot应用程序 mvn archetype:generate “-DarchetypeGroupId=com.sap.cloud.sdk.archetypes” “-DarchetypeArtifactId=scp-cf-spring” “-DarchetypeVersion=RELEASE”  “-DgroupId=com.sap.sdk” “-DartifactId=expresscost3” “-Dpackage=com.sap.cap.expresscost3”   步骤3,在expresscost3/application/pom.xml中添加以下依赖项 <dependency> <groupId>org.apache.httpcomponents</groupId> <artifactId>httpclient</artifactId> <version>4.5.14</version> </dependency> <dependency> <groupId>com.alibaba</groupId> <artifactId>fastjson</artifactId> <version>2.0.31</version> </dependency> <dependency> <groupId>com.google.code.gson</groupId> <artifactId>gson</artifactId> <version>2.10.1</version> </dependency>   步骤4,在包com.sap.cap.expresscost3下添加包 service 步骤5,在包service下添加类Service,代码如下: package …

开发Spring-boot应用程序,连接菜鸟物流平台Api并将其部署到BTP Cloud Foundry Read More »

Business Event Triggers in SAP Build Process Automation for SAP S/4HANA: Manage Credit Block on Sales Orders

SAP Build Process Automation is a simpler and faster way to automate business processes. It provides a unified Low-Code/No-code development experience to combine orchestrated workflows with Robotics Process Automation and Business AI in a single development environment. Check here for What’s New and Learn more from the roadmap.   In my Blog post Business Event Triggers in SAP Build …

Business Event Triggers in SAP Build Process Automation for SAP S/4HANA: Manage Credit Block on Sales Orders Read More »

SAP Build Apps Application to show Data from ODATA S4 System in tubular format

Motivation:- In this blog you will learn how to display data in SAP Build Apps web application from SAP ODATA Service. Overview:- The SAP Build apps low code/no code solutions which enable users of all skill levels to easily create the business applications. This approach help users to create applications and automate the  processes, Developer …

SAP Build Apps Application to show Data from ODATA S4 System in tubular format Read More »

Accelerate Business Value and Innovation with Modern Integration – Join the Webcast

As organizations work on digital transformation or automation initiatives, updating IT technology is imperative to take advantage of the latest innovations, and to drive new business value while reducing costs. This all starts with modernizing your integration layer. SAP’s integration approach and solutions go far beyond the technical integration of applications. It delivers the holistic integration …

Accelerate Business Value and Innovation with Modern Integration – Join the Webcast Read More »

SAP Cloud Integration: How to call Azure Application from iFlow (Outbound)

SAP Cloud Integration (aka CPI) allows to call an external REST endpoint from an iFlow via HTTP (receiver adapter). It supports authentication like OAuth, Basic Auth and Client Certificate for calling a protected endpoint. In case of OAuth, it means that Cloud Integration is able to fetch a JWT token and send it to the …

SAP Cloud Integration: How to call Azure Application from iFlow (Outbound) Read More »

New pilot service to help customers prepare critical integration scenarios to migrate to SAP Integration Suite

Customers are starting to future-proof their integration scenarios by moving to the cloud and migrating their SAP Process Orchestration systems to the SAP Integration Suite. As you may be aware, earlier this year SAP released their SAP Assessment and Migration Tools to support migration projects. Through the tools customers have a good overview on your …

New pilot service to help customers prepare critical integration scenarios to migrate to SAP Integration Suite Read More »

AI in SAP BTP: Q3 2023 Highlights – SAP AI Business Services, SAP AI Core and SAP AI Launchpad

Dear SAP Community, As stated by SAP CTO’s Juergen Mueller, SAP Business Technology Platform acts as the enabler for SAP and partner applications to leverage AI capabilities, including generative AI, in an SAP context. With SAP Business AI, your company can benefit from relevant, reliable, and responsible built-in AI for your core business processes. SAP …

AI in SAP BTP: Q3 2023 Highlights – SAP AI Business Services, SAP AI Core and SAP AI Launchpad Read More »

Scroll to Top