天天看點

如何用Java代碼在SAP Marketing Cloud裡建立contact資料

我們可以使用SAP Marketing Cloud提供的Contact create OData API在第三方應用裡建立Contact主資料.

API位址:/sap/opu/odata/sap/CUAN_CONTACT_SRV/InteractionContacts

示例代碼隻有100多行:

如何用Java代碼在SAP Marketing Cloud裡建立contact資料
如何用Java代碼在SAP Marketing Cloud裡建立contact資料
如何用Java代碼在SAP Marketing Cloud裡建立contact資料

上述代碼裡,我寫死了一個Contact的姓為SAP Wang,名為SAP diablo,

執行之後, 列印出API消費成功的201代碼。

寫死的資料能夠在Marketing Cloud裡觀察到。

上述源代碼在我的github上也能看到:https://github.com/i042416/JavaTwoPlusTwoEquals5/blob/master/src/partner1/SimpleContactCreator.java

如何用Java代碼在SAP Marketing Cloud裡建立contact資料