ADDEDIT BrandAdvertiserEvent API Version 1


Updated on 2018-01-18
Current Version: Version 1
Deprecated Version: NA
Requests Allowed: GET&SOAP
 


Summary:

This API will allow to create or edit events found under the Advertiser/Brand Cards in CAKE.


Resource/WSDL Page:

http://<your_domain_here>/api/1/addedit.asmx?op=BrandAdvertiserEvent


Parameters

api_key
Required
Type: STRING
Length (Max/Min): 50
Must be a valid API Key (existing and NOT expired)
Example Values: Fo35NRAqvFLXoZxqB4aViaiYM7iVMhh
event_id
Required
Type: INT
Length (Max/Min): NA
Enter 0 to create a new event or an existing event ID to edit, this Event ID is found on the Advertiser/Brand Card.
EXPORT Advertisers API version 6:
https://support.getcake.com/solution/articles/13000001689-export-advertisers-api-version-6
Example Values: 52
brand_advertiser_id
Required
Type: INT
Length (Max/Min): NA
This field is required only if event_id is greater than 0 or editing an existing event.


Example Values: 2
event_name
Required
Type: STRING
Length (Max/Min): NA
The field is required for event creation, leaving this field empty will skip on edit.


Example Values: 3
third_party_name
Required
Type: STRING
length (Max/Min): 30
Leaving this field empty will skip. 'NULL' will remove the value.


Example Values: CAKE
event_type
Required
Type: ENUM
Length (Max/Min): NA
Updates event type.


Example Values: conversion_macro_event, micro_event, no_change
price_format_id
Required
Type: INT
Length (Max/Min): NA
Enter 0 for no change.
On creation, you cannot pass 0
This is only valid for CPE and RevShare formats
Example Values: 2
active
Required
Type: ENUM
Length (Max/Min): NA
On creation, you cannot pass 'no_change'
This setting is for non-default events or micro_events

Example Values: on, off, no_change
allow_duplicates
Required
Type: ENUM
Length (Max/Min): NA
On creation, you cannot pass 'no_change'


Example Values: on, off, no_change
transaction_id_deduplication_type
Required
Type: ENUM
Length (Max/Min): NA
On creation, you cannot pass 'no_change'
This setting is for non-default events or micro_events

Example Values: by_brand_advertiser or by_site_offer or disabled or no_change
payout_modification_type
Required
Type: ENUM
Length (Max/Min): NA



Example Values: do_not_change or change
payout
Required
Type: DECIMAL
Length (Max/Min): NA
Cannot submit a Received value when modifying the Default Event
This setting is for non-default events or micro_events


Example Values: 10.5
received_modification_type
Required
Type: ENUM
Length (Max/Min): NA



Example Values: do_not_change or change
received
Required
Type: DECIMAL
Length (Max/Min): NA
Cannot submit a Received value when modifying the Default Event
This setting is for non-default events or micro_events


Example Values: 23.6
received_percentage
Required
Type: ENUM
Length (Max/Min): NA
On creation cannot pass 'no_change'
This setting is for non-default events or micro_events

Example Values: on, off, no_change
event_payout_and_received_trump_other_sources
Required
Type: ENUM
Length (Max/Min): NA
On creation cannot pass 'no_change'
This setting is for non-default events or micro_events

Example Values: on, off, no_change
default_active_for_all_site_offers
Required
Type: ENUM
Length (Max/Min): NA
On creation cannot pass 'no_change'
This setting is for non-default events or micro_events

Example Values: on, off, no_change
portal
Required
Type: ENUM
Length (Max/Min): NA
On creation cannot pass 'no_change'
This setting is for non-default events or micro_events

Example Values: on, off, no_change
suppress_source_affiliate_pixel
Required
Type: ENUM
Length (Max/Min): NA
On creation cannot pass 'no_change'


Example Values: on, off, no_change
fire_global_pixel
Required
Type: ENUM
Length (Max/Min): NA
On creation cannot pass 'no_change'
This setting is for non-default events or micro_events

Example Values: on, off, no_change
postback_url
Required
Type: STRING
Length (Max/Min): NA
Leave empty and this will skip field
'NULL' removes current value stored
This setting is for non-default events
Example Values: https://google.com
postback_delay_ms
Required
Type: INT
Length (Max/Min): NA
-1 means skip
-2 removes values
This setting is for non-default events or micro_events
Example Values: 1.2
pixel_html
Required
Type: STRING
Length (Max/Min): NA
empty means skip
'NULL' removes values
This setting is for non-default events or micro_events
Example Values: https://google.com



 

Example Request

GET http://staging.cakemarketing.com/api/1/addedit.asmx/BrandAdvertiserEvent?api_key=dNJFmId9rI&&event_id=0&brand_advertiser_id=902109&event_name=upsell&third_party_name=hello%20world&event_type=micro_event&price_format_id=1&active=on&allow_duplicates=on&transaction_id_deduplication_type=disabled&payout_modification_type=do_not_change&payout=20.3&received_modification_type=change&received=45.3&received_percentage=on&event_payout_and_received_trump_other_sources=on&default_active_for_all_site_offers=on&portal=on&suppress_source_affiliate_pixel=on&fire_global_pixel=off&postback_url=http://google.com&postback_delay_ms=1&pixel_html=http://yahoo.com

 

Sample XML Response on creation:

<advertiser_brand_event_addedit_response xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://cakemarketing.com/api/1/">
<success>true</success>
<message>Event 3384 Created.</message>
<row_count>0</row_count>
<success_info>
<event_id>3384</event_id>
</success_info>
</advertiser_brand_event_addedit_response>


Sample XML Response on edit:


<advertiser_brand_event_addedit_response xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://cakemarketing.com/api/1/">
<success>true</success>
<message>Event 3384 Updated.</message>
<row_count>0</row_count>
<success_info>
<event_id>3384</event_id>
</success_info>
</advertiser_brand_event_addedit_response>