diff --git a/FuelSDK/objects.py b/FuelSDK/objects.py index 895ef1a..edf3fe5 100644 --- a/FuelSDK/objects.py +++ b/FuelSDK/objects.py @@ -71,7 +71,19 @@ def __init__(self): self.endpoint = 'https://www.exacttargetapis.com/hub/v1/campaigns/{id}/assets/{assetId}' self.urlProps = ["id", "assetId"] self.urlPropsRequired = ["id"] - + +######## +## +## wrap an Exact Target Interaction Events +## +######## +class ET_InteractionEvents(ET_CUDSupportRest): + def __init__(self): + super(ET_InteractionEvents, self).__init__() + self.endpoint = 'https://www.exacttargetapis.com/interaction/v1/events' + self.urlProps = [] + self.urlPropsRequired = [] + ######## ## ## wrap an Exact Target Click Event diff --git a/objsamples/sample_interaction.py b/objsamples/sample_interaction.py new file mode 100644 index 0000000..13f581a --- /dev/null +++ b/objsamples/sample_interaction.py @@ -0,0 +1,32 @@ +import ET_Client + +try: + debug = False + stubObj = ET_Client.ET_Client(False, debug) + + # In order for this sample to run, it needs to have a interaction. + SubscriberKey = "123456789" + EventDefinitionKey = "ContactEvent-xxxxxxxx" + + # Event Fire for interaction + print '>>> Event Fire for interaction' + postInteractionEvent = ET_Client.ET_InteractionEvents() + postInteractionEvent.auth_stub = stubObj + postInteractionEvent.props = { + "ContactKey": SubscriberKey, + "EventDefinitionKey": EventDefinitionKey, + "Data": { + "Id":"01234567", + "Foo":"Bar" + } + } + postInteractionEventResponse = postInteractionEvent.post() + + print 'PostRequest Status: ' + str(postInteractionEventResponse.status) + print 'Code: ' + str(postInteractionEventResponse.code) + print 'eventInstanceId: ' + str(postInteractionEventResponse.results['eventInstanceId']) + print '-----------------------------' + +except Exception as e: + print 'Caught exception: ' + e.message + print e \ No newline at end of file pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy