Zuordnen von Segmenten zu einem Ziel
- Themen:
- API
Ordnen Sie mit diesen RESTful API Methoden Segmente Zielen zu.
Unterstützte Zieltypen: nur URL und Cookie
Mit den verfügbaren POST
können Sie Segmente nur URL und cookie destinations zuordnen. Derzeit können Sie mit diesen REST API keine Segmente server-to-server destinations zuordnen. Verwenden Sie stattdessen die -Benutzeroberfläche. Mit den zugehörigen Ziel-GET
-Methoden können Sie jedoch Informationen zu server-to-server destinations abrufen, die in der Benutzeroberfläche erstellt wurden.
Zuordnen eines Segments zu einem nicht serialisierten URL-Ziel
Eine POST
Methode, mit der Sie ein Segment einem nicht seriellen URL zuordnen können.
Anfrage
POST https://api.demdex.com/v1/destinations/
<destinationId>
/mappings/
Beispielanforderung
Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
{
"sid":87723,
"traitType":"SEGMENT",
"url":"https://adobe.com",
"startDate":"2012-07-04"
}
Antwort
{
"mappingId":65334,
"traitType":"SEGMENT",
"traitValue":0,
"destinationId":4033,
"elementName":"Sample games",
"elementDescription":"Sample games pixel",
"elementStatus":"active",
"createTime":1338940094000,
"updateTime":1338940094000,
"crUID":694,
"upUID":694,
"sid":87723,
"startDate":"2012-07-03",
"endDate":null,
"priority":null,
"url":"https://adobe.com",
"secureUrl":null,
"tagCode":null,
"secureTagCode":null,
"traitAlias":null
}
Zuordnen eines Segments zu einem serialisierten URL-Ziel
Eine POST
Methode, mit der Sie ein Segment einem serialisierten URL zuordnen können.
Anfrage
POST https://api.demdex.com/v1/destinations/
<dataOrderId>
/traits/
Beispielanforderung
In der Anfrage entspricht der traitAlias
dem Schlüssel in einem Schlüssel-Wert-Paar. Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
{
"sid":87723,
"traitType":"SEGMENT",
"startDate":"2012-07-04",
"traitAlias":"123"
}
Antwort
{
"mappingId":65335,
"traitType":"SEGMENT",
"traitValue":0,
"destinationId":4034,
"elementName":"Sample Games",
"elementDescription":"Migration of Sample Games Pixel",
"elementStatus":"active",
"createTime":1338940401000,
"updateTime":1338940401000,
"crUID":694,
"upUID":694,
"sid":87723,
"startDate":"2012-07-03",
"endDate":null,
"priority":null,
"url":"123",
"secureUrl":"123",
"tagCode":null,
"secureTagCode":null,
"traitAlias":"123"
}
Zuordnen eines Segments zu einem Cookie-Ziel: Einzelschlüssel, nicht serialisiert
Eine POST
Methode, mit der Sie ein Segment einem nicht serialisierten Einzelschlüssel-cookie zuordnen können.
Anfrage
POST https://api.demdex.com/v1/destinations/
<destinationId>
/mappings/
Beispielanforderung
In der Anfrage entspricht der valueAlias
dem Wert in einem Schlüssel-Wert-Paar. Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
{
"sid":87723,
"traitType":"SEGMENT",
"startDate":"2012-07-04",
"valueAlias":"123"
}
Antwort
{
"destinationMappingId":65336,
"traitType":"SEGMENT",
"traitValue":0,
"destinationId":4035,
"elementName":"Sample Games",
"elementDescription":"Migration of Sample Games Pixel",
"elementStatus":"active",
"createTime":1338940704000,
"updateTime":1338940704000,
"crUID":694,
"upUID":694,
"sid":87723,
"startDate":"2012-07-03",
"endDate":null,
"priority":1,
"traitAlias":null,
"valueAlias":"123"
}
Zuordnen eines Segments zu einem Cookie-Ziel: Mehrschlüssel, nicht serialisiert
Eine POST
Methode, mit der Sie ein Segment einem nicht serialisierten Mehrschlüssel-cookie zuordnen können.
Anfrage
POST https://api.demdex.com/v1/destinations/
<destinationId>
/mappings/
Beispielanforderung
In der Anfrage legen die traitAlias
und valueAlias
den Schlüssel bzw. den Wert in einem Schlüssel-Wert-Paar fest. Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
{
"sid":87723,
"traitType":"SEGMENT",
"startDate":"2012-07-04",
"traitAlias":"type",
"valueAlias":"123"
}
Antwort
{
"mappingId":65338,
"traitType":"SEGMENT",
"traitValue":0,
"destinationId":4037,
"elementName":"Sample Games",
"elementDescription":"Migration of Sample Games Pixel",
"elementStatus":"active",
"createTime":1338941092000,
"updateTime":1338941092000,
"crUID":694,
"upUID":694,
"sid":87723,
"startDate":"2012-07-03",
"endDate":null,
"priority":1,
"traitAlias":"type",
"valueAlias":"123"
}
Zuordnen eines Segments zu einem Cookie-Ziel: Mehrschlüssel, serialisiert
Eine POST
Methode, mit der Sie ein Segment einem serialisierten cookie destination mit mehreren Schlüsseln zuordnen können.
Anfrage
POST https://api.demdex.com/v1/destinations/
<destinationId>
/mappings/
Beispielanforderung
In der Anfrage legen traitAlias
und valueAlias
den Schlüssel und den Wert in einem Schlüssel-Wert-Paar fest. Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
{
"sid":87723,
"traitType":"SEGMENT",
"startDate":"2012-07-04",
"traitAlias":"type",
"valueAlias":"123"
}
Antwort
{
"destinationMappingId":65340,
"traitType":"SEGMENT",
"traitValue":0,
"destinationId":4038,
"elementName":"Sample Games",
"elementDescription":"Migration of Sample Games Pixel",
"elementStatus":"active",
"createTime":1338941273000,
"updateTime":1338941273000,
"crUID":694,
"upUID":694,
"sid":87723,
"startDate":"2012-07-03",
"endDate":null,
"priority":2,
"traitAlias":"type",
"valueAlias":"123"
}
Zuordnen eines Segments zu einem Server-zu-Server-Ziel
Eine POST
Methode, mit der Sie ein Segment einem vorhandenen server-to-server zuordnen können. Beachten Sie jedoch, dass Sie mit diesen derzeit verfügbaren API keine server-to-server Ziele erstellen können.
Anfrage
POST https://api.demdex.com/v1/destinations/
<destinationId>
/mappings/
Beispielanforderung
In der Anfrage entspricht der traitAlias
dem Schlüssel in einem Schlüssel-Wert-Paar. Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
{
"sid":87723,
"traitType":"SEGMENT",
"startDate":"2012-07-04",
"traitAlias":"123"
}
Antwort
{
"destinationMappingId":65341,
"traitType":"SEGMENT",
"traitValue":0,
"destinationId":566,
"elementName":"Sample",
"elementDescription":"",
"elementStatus":"active",
"createTime":1338942118000,
"updateTime":1338942118000,
"crUID":308,
"upUID":308,
"sid":84326,
"startDate":"2012-07-03",
"endDate":null,
"priority":null,
"traitAlias":"123"
}
Massen-Erstellung von Zielzuordnungen
Eine POST
Methode, mit der Sie ein Array von cookie- oder URL übergeben können.
Anfrage
POST https://api.demdex.com/v1/destinations/
<destinationId>
/bulk-create
Beispielanforderung
Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
[
{
"sid": 105123,
"traitType":"SEGMENT",
"url":"https://adobe.com",
"startDate":"2012-11-20"
},
{
"sid": 121070,
"traitType":"SEGMENT",
"url":"https://my.adobeconnect.com",
"startDate":"2012-11-21"
}
]
Antwort
Eine erfolgreiche Antwort gibt das Array der erstellten Zuordnungen zurück.
[
{
"mappingId": 103454,
"traitType": "SEGMENT",
"traitValue": 0,
"destinationId": 780,
"elementName": "Case of the Mondays",
"elementDescription": "test",
"elementStatus": "active",
"createTime": 1353373234000,
"updateTime": 1353373234000,
"crUID": 1065,
"upUID": 1065,
"sid": 105123,
"startDate": "2012-11-19",
"endDate": null,
"priority": null,
"url": "https://adobe.com",
"secureUrl": null,
"tagCode": null,
"secureTagCode": null,
"traitAlias": null
},
{
"mappingId": 103455,
"traitType": "SEGMENT",
"traitValue": 0,
"orderId": 780,
"elementName": "Test Trait",
"elementDescription": "This trait",
"elementStatus": 1,
"createTime": 1353373234000,
"updateTime": 1353373234000,
"crUID": 1065,
"upUID": 1065,
"sid": 121070,
"startDate": "2012-11-20",
"endDate": null,
"priority": null,
"url": "https://my.adobeconnect.com",
"secureUrl": null,
"tagCode": null,
"secureTagCode": null,
"traitAlias": null
}
]
Hinzufügen mehrerer Segmente zu einem Ziel
Eine POST
Methode, mit der Sie einem Ziel mehrere Segmente zuordnen können.
Anfrage
POST https://api.demdex.com/v1/destinations/
<destinationId>
bulk-create
Beispielanforderung
Erstellen Sie mehrere Zielzuordnungen in einem Array. Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
[
{
"sid": 105123,
"traitType":"SEGMENT",
"url":"https://adobe.com",
"startDate":"2012-11-20"
},
{
"sid": 121070,
"traitType":"SEGMENT",
"url":"https://my.adobeconnect.com",
"startDate":"2012-11-21"
}
]
Antwort
Gibt ein Array der erstellten Zuordnungen zurück.
[
{
"destinationMappingId": 103454,
"traitType": "SEGMENT",
"traitValue": 0,
"destinationId": 780,
"elementName": "Case of the Mondays",
"elementDescription": "test",
"elementStatus": "active",
"createTime": 1353373234000,
"updateTime": 1353373234000,
"crUID": 1065,
"upUID": 1065,
"sid": 105123,
"startDate": "2012-11-19",
"endDate": null,
"priority": null,
"url": "https://adobe.com",
"secureUrl": null,
"tagCode": null,
"secureTagCode": null,
"traitAlias": null
},
{
"traitToDataOrderId": 103455,
"traitType": "SEGMENT",
"traitValue": 0,
"destinationId": 780,
"elementName": "Test Trait",
"elementDescription": "This trait",
"elementStatus": 1,
"createTime": 1353373234000,
"updateTime": 1353373234000,
"crUID": 1065,
"upUID": 1065,
"sid": 121070,
"startDate": "2012-11-20",
"endDate": null,
"priority": null,
"url": "https://my.adobeconnect.com",
"secureUrl": null,
"tagCode": null,
"secureTagCode": null,
"traitAlias": null
}
]
Aktualisieren eines Ziels nach Ziel-ID
Eine PUT
Methode, mit der Sie ein vorhandenes Ziel destinationId
aktualisieren können.
Anfrage
PUT https://api.demdex.com/v1/destinations/
<destinationId>
Beispielanforderung
Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
{
"name":"Updated URL Destination (not serialized)",
"description":"new description",
"destinationType":"PUSH",
"serializationEnabled":false
}
Antwort
{
"destinationType": "PUSH",
"destinationId": 780,
"dataSourceId": null,
"pid": 1099,
"name": "Updated URL Destination (not serialized)",
"description": "new description",
"startDate": null,
"endDate": null,
"status": 1,
"createTime": 1348851790000,
"updateTime": 1353372029000,
"crUID": 884,
"upUID": 1065,
"domainRestrictions":"all_domains",
"tagType": 0,
"serializationEnabled": false,
"urlFormatString": null,
"secureUrlFormatString": null,
"delimiter": null,
"mappings": null
}
Aktualisieren einer Zuordnung zu einem Ziel durch Zuordnungs-ID
Eine PUT
Methode, mit der Sie eine Zuordnung zu einem Ziel um den angegebenen mappingId
aktualisieren können.
Anfrage
PUT https://api.demdex.com/v1/destinations/mappings/
<mappingId>
Beispielanforderung
Alle Anfragewerte sind erforderlich, sofern nicht anders angegeben.
{
"sid": 105123,
"traitType":"SEGMENT",
"url":"https://adobe.com",
"startDate":"2012-11-20"
}
Antwort
{
"mappingId": 103453,
"traitType": "SEGMENT",
"traitValue": 0,
"destinationId": 780,
"elementName": "sample",
"elementDescription": "test",
"elementStatus": "active",
"createTime": 1353373005000,
"updateTime": 1353373005000,
"crUID": 1065,
"upUID": 1065,
"sid": 105123,
"startDate": "2012-11-19",
"endDate": null,
"priority": null,
"url": "https://www.adobe.com/send?%ALIAS%",
"secureUrl": null,
"tagCode": null,
"secureTagCode": null,
"traitAlias": null
}