ADDEDIT Caps API Version 1
Updated on 2014-5-2
Current Version: Version 1
Deprecated Version: N/A
Requests Allowed: GET/SOAP
Summary:
Allows you to create or update Cap details for an offer/campaign in CAKE.
Resource/WSDL Page:
http://yourdomainhere/api/1/addedit.asmx?op=Caps
Parameters
api_key | This api_key will provide you with the ability to export Campaigns for your instance. You can obtain this api_key from within CAKE >> Setup >> Permissions in the API Key list. Example Values: Fo35NRAqvFLXoZxqB4aViaiYM7iVMhh |
offer_id | This is the identifier for a unique Offer. This can be found on any Offer card. 0 to skip Example Values: 1234 |
offer_contract_id | This is the identifier for a unique Offer Contract ID. 0 to skip Example Values: 1234 |
campaign_id | This is the identifier for a unique campaign. You can obtain the campaign ID from your CAKE instance on the campaign card. To get there, go to the advertiser tab >> offers >> choose an offer to open the offer card >> campaign tab >> choose a campaign >> ID. 0 to skip Example Values: 1234 |
cap_type_id | Click cap = 1
|
cap_interval_id | Set to null=-1 Lifetime = 0
|
cap_amount | Specific amount for the cap. -1 to set to NULL Example Values: 1234 |
cap_start | Start date for the cap. only used if cap_interval_id is custom (4)
|
send_alert_only | Should an alert be sent or not? Example Values: TRUE |
**Note all optional parameters still need to be passed through in the actual call. These parameters do not need a value (therefore you can use a null value).
Example Request
GET |
Sample XML Response:
<caps_addedit_response> <success>true</success> <message>Cap Updated</message> </caps_addedit_response> |
Example Error Messages:
Error Message | Likely Cause |
Invalid API Key | API key does not exist or is expired. |
Invalid Campaign | no campaign found for the specified campaign_id |
Invalid Offer Contract | no offer contract found for the specified offer_contract_id |
Invalid Offer | no offer found for the specified offer_id |
Invalid Cap Type | no cap type found for the specified cap_type_id |
Invalid Cap Interval | no cap interval found for the specified cap_interval_id or you passed a 0 cap_interval_id and a cap_amount that doesn't equal -1 |
Update Error - Campaign ID: ### | general error when the campaign save fails |
Update Error - Offer Contract ID: ### | general error when the offer contract save fails |
Update Error - Offer ID: ### | general error when the offer save fails |