結構資料庫中的所有資源都包含在IMS組織內的特定沙箱中。 在某些情況下,您可能會想在沙箱與IMS組織之間共用Experience Data Model(XDM)資源。
為滿足此需求, 結構 Adobe Experience Platform UI中的工作區可讓您為架構資料庫中的任何架構產生匯出裝載。 接著,此裝載便可用於呼叫結構註冊表API,以將結構(以及所有相依資源)匯入目標沙箱和IMS組織。
除了結構(包括類、結構欄位組和資料類型)外,您還可以使用結構註冊表API導出其他資源。 請參閱 匯出端點指南 以取得更多資訊。
雖然Platform UI可讓您匯出XDM資源,但您必須使用「結構註冊表API」將這些資源匯入其他沙箱或IMS組織,才能完成工作流程。 請參閱 架構註冊表API快速入門 如需遵循本指南之前所需驗證標題的重要資訊。
在平台UI中,選取 結構 的下一頁。 在 結構 工作區,找出您要匯出的結構,並在 Schema Editor.
請參閱 探索XDM資源 以取得如何尋找您所尋找之XDM資源的詳細資訊。
開啟架構後,請選取 複製JSON 圖示()。
這會根據結構,將JSON裝載複製到剪貼簿。 針對「Loyalty Members"結構(如上所示)會產生下列JSON:
[
{
"$id": "https://ns.adobe.com/<XDM_TENANTID_PLACEHOLDER>/mixins/9ecfd881d0053568d277b792e4d24c6b70ffa7782bd31265",
"meta:altId": "_<XDM_TENANTID_PLACEHOLDER>.mixins.9ecfd881d0053568d277b792e4d24c6b70ffa7782bd31265",
"meta:resourceType": "mixins",
"version": "1.0",
"title": "Loyalty details",
"type": "object",
"description": "",
"definitions": {
"customFields": {
"type": "object",
"properties": {
"_<XDM_TENANTID_PLACEHOLDER>": {
"type": "object",
"properties": {
"loyalty": {
"title": "Loyalty",
"description": "",
"type": "object",
"isRequired": false,
"required": [
],
"properties": {
"loyaltyId": {
"title": "Loyalty ID",
"description": "",
"type": "string",
"isRequired": false,
"required": [
],
"meta:xdmType": "string"
},
"memberSince": {
"title": "Member Since",
"description": "",
"type": "string",
"isRequired": false,
"required": [
],
"format": "date",
"meta:xdmType": "date"
},
"points": {
"title": "Points",
"description": "",
"type": "integer",
"isRequired": false,
"required": [
],
"meta:xdmType": "int"
},
"loyaltyLevel": {
"title": "Loyalty Level",
"description": "",
"type": "string",
"isRequired": false,
"required": [
],
"enum": [
"platinum",
"gold",
"silver",
"bronze"
],
"meta:enum": {
"platinum": "Platinum",
"gold": "Gold",
"silver": "Silver",
"bronze": "Bronze"
},
"meta:xdmType": "string"
}
},
"meta:xdmType": "object"
}
},
"meta:xdmType": "object"
}
},
"meta:xdmType": "object"
}
},
"allOf": [
{
"$ref": "#/definitions/customFields",
"type": "object",
"meta:xdmType": "object"
}
],
"meta:extensible": true,
"meta:abstract": true,
"meta:intendedToExtend": [
],
"meta:xdmType": "object",
"meta:sandboxId": "1bd86660-c5da-11e9-93d4-6d5fc3a66a8e",
"meta:sandboxType": "production"
},
{
"$id": "https://ns.adobe.com/<XDM_TENANTID_PLACEHOLDER>/schemas/1e5a739ded8fd1d766a0e06e881a38031874dddd1c7020ad",
"meta:altId": "_<XDM_TENANTID_PLACEHOLDER>.schemas.1e5a739ded8fd1d766a0e06e881a38031874dddd1c7020ad",
"meta:resourceType": "schemas",
"version": "1.4",
"title": "Loyalty Members",
"type": "object",
"description": "Describes customers who are members of a loyalty program.",
"allOf": [
{
"$ref": "https://ns.adobe.com/xdm/context/profile",
"type": "object",
"meta:xdmType": "object"
},
{
"$ref": "https://ns.adobe.com/xdm/context/profile-person-details",
"type": "object",
"meta:xdmType": "object"
},
{
"$ref": "https://ns.adobe.com/xdm/context/profile-personal-details",
"type": "object",
"meta:xdmType": "object"
},
{
"$ref": "https://ns.adobe.com/<XDM_TENANTID_PLACEHOLDER>/mixins/9ecfd881d0053568d277b792e4d24c6b70ffa7782bd31265",
"type": "object",
"meta:xdmType": "object"
},
{
"$ref": "https://ns.adobe.com/xdm/mixins/profile-consents",
"type": "object",
"meta:xdmType": "object"
}
],
"meta:extensible": false,
"meta:abstract": false,
"meta:extends": [
"https://ns.adobe.com/xdm/context/profile-person-details",
"https://ns.adobe.com/xdm/context/profile-personal-details",
"https://ns.adobe.com/xdm/common/auditable",
"https://ns.adobe.com/xdm/data/record",
"https://ns.adobe.com/xdm/context/profile",
"https://ns.adobe.com/<XDM_TENANTID_PLACEHOLDER>/mixins/9ecfd881d0053568d277b792e4d24c6b70ffa7782bd31265",
"https://ns.adobe.com/xdm/mixins/profile-consents"
],
"meta:xdmType": "object",
"meta:class": "https://ns.adobe.com/xdm/context/profile",
"meta:sandboxId": "1bd86660-c5da-11e9-93d4-6d5fc3a66a8e",
"meta:sandboxType": "production",
"meta:immutableTags": [
]
}
]
裝載會以陣列的形式呈現,而每個陣列項目都是代表要匯出之自訂XDM資源的物件。 在上例中,Loyalty details"自定義欄位組和"Loyalty Members」架構。 匯出中不包含結構採用的任何核心資源,因為這些資源可用於所有沙箱和IMS組織。
請注意,您組織的租用戶ID的每個例項都顯示為 <XDM_TENANTID_PLACEHOLDER>
在裝載中。 視您在下個步驟中匯入結構的位置而定,這些預留位置會自動取代為適當的租用戶ID值。
複製結構的匯出JSON後,您就可以將它當作POST要求的裝載,傳送至 /rpc/import
結構註冊表API中的端點。 請參閱 匯入端點指南 如需如何設定呼叫以傳送結構給所需IMS組織和沙箱的詳細資訊。
依照本指南,您已成功將XDM結構匯出至不同的IMS組織或沙箱。 如需功能的詳細資訊,請參閱 結構 UI,請參閱 結構 UI概述.