[舊版]{class="badge informative"}
查詢個人化優惠方案 look-up-personalized-offer
TIP
Adobe Journey Optimizer 的新決策功能「決策」現在可透過程式碼型體驗和電子郵件管道使用!了解更多
個人化優惠是根據適用性規則和限制的可自訂行銷訊息。
您可以向優惠資料庫 API發出GET請求,在請求路徑中包含個人化優惠@id或個人化優惠的名稱,以查詢特定的個人化優惠。
API格式
GET /{ENDPOINT_PATH}/{CONTAINER_ID}/queries/core/search?schema={SCHEMA_PERSONALIZED_OFFER}&{QUERY_PARAMS}
參數
說明
範例
{ENDPOINT_PATH}存放庫API的端點路徑。
https://platform.adobe.io/data/core/xcore/{CONTAINER_ID}個人化優惠所在的容器。
e0bd8463-0913-4ca1-bd84-6309134ca1f6{SCHEMA_PERSONALIZED_OFFER}定義與個人化優惠相關聯的結構描述。
https://ns.adobe.com/experience/offer-management/personalized-offer;version=0.5id用於比對實體
@id屬性的字串。 字串完全相符。 引數"id"和"name"不能一起使用。xcore:personalized-offer:124cc332095cfa74name用於比對實體的xdm:name屬性的字串。 字串以大寫完全相符,但可使用萬用字元。 引數
id和name不能一起使用Discount offer要求
curl -X GET \
'https://platform.adobe.io/data/core/xcore/e0bd8463-0913-4ca1-bd84-6309134ca1f6/instances?schema=https://ns.adobe.com/experience/offer-management/personalized-offer;version=0.5&name=Discount%20offer' \
-H 'Accept: *,application/vnd.adobe.platform.xcore.hal+json; schema="https://ns.adobe.com/experience/xcore/hal/results"' \
-H 'Authorization: Bearer {ACCESS_TOKEN}' \
-H 'x-api-key: {API_KEY}' \
-H 'x-gw-ims-org-id: {IMS_ORG}' \
-H 'x-sandbox-name: {SANDBOX_NAME}'
回應
成功的回應會傳回位置詳細資料,包括容器ID、執行個體ID和唯一個人化優惠@id的相關資訊。
{
"containerId": "e0bd8463-0913-4ca1-bd84-6309134ca1f6",
"schemaNs": "https://ns.adobe.com/experience/offer-management/personalized-offer;version=0.5",
"requestTime": "2023-10-21T20:59:16.238585Z",
"_embedded": {
"results": [
{
"instanceId": "fb2aad00-130e-11eb-aa26-21e7b1fa6da6",
"schemas": [
"https://ns.adobe.com/experience/offer-management/personalized-offer;version=0.5"
],
"productContexts": [
"acp"
],
"repo:etag": 1,
"repo:createdDate": "2023-10-20T20:01:02.927874Z",
"repo:lastModifiedDate": "2023-10-20T20:01:02.927874Z",
"repo:createdBy": "{CREATED_BY}",
"repo:lastModifiedBy": "{MODIFIED_BY}",
"repo:createdByClientId": "{CREATED_CLIENT_ID}",
"repo:lastModifiedByClientId": "{MODIFIED_CLIENT_ID}",
"_score": 0,
"_instance": {
"xdm:name": "Discount offer",
"xdm:representations": [
{
"xdm:components": [
{
"dc:language": [
"en"
],
"@type": "https://ns.adobe.com/experience/offer-management/content-component-json",
"dc:format": "application/json"
}
],
"xdm:placement": "xcore:offer-placement:12428d436d87dc84"
}
],
"xdm:rank": {
"xdm:priority": 1
},
"xdm:selectionConstraint": {
"xdm:startDate": "2023-10-01T16:00:00Z",
"xdm:endDate": "2021-12-13T16:00:00Z",
"xdm:eligibilityRule": "xcore:eligibility-rule:124cb4511da781fc"
},
"xdm:status": "draft",
"xdm:cappingConstraint": {
"xdm:globalCap": 150
},
"xdm:tags": [
"xcore:tag:1246d138ec8cca1f"
],
"@id": "xcore:personalized-offer:124cc332095cfa74"
},
"_links": {
"self": {
"name": "https://ns.adobe.com/experience/offer-management/personalized-offer;version=0.5#fb2aad00-130e-11eb-aa26-21e7b1fa6da6",
"href": "/e0bd8463-0913-4ca1-bd84-6309134ca1f6/instances/fb2aad00-130e-11eb-aa26-21e7b1fa6da6",
"@type": "https://ns.adobe.com/experience/offer-management/personalized-offer;version=0.5"
}
}
}
],
"total": 1,
"count": 1
},
"_links": {
"self": {
"href": "/e0bd8463-0913-4ca1-bd84-6309134ca1f6/instances?schema=https://ns.adobe.com/experience/offer-management/personalized-offer;version=0.5&name=Discount%20offer",
"@type": "https://ns.adobe.com/experience/xcore/hal/results"
}
}
}
recommendation-more-help
b22c9c5d-9208-48f4-b874-1cefb8df4d76