Difference between revisions of "Offerit API Add Offer"
From Offerit
OfferitSopko (talk | contribs) (Created page with "{{Offerit Manual | show_api_admin_section = true }} This function allows for you to add an offer into Offerit. To use this function, you must make a SOAP call with the following...") |
(No difference)
|
Revision as of 11:54, 17 April 2013
This function allows for you to add an offer into Offerit. To use this function, you must make a SOAP call with the following parameters:
Offer Settings:
- offer_name - Name of the Offer to be created.
- url - The URL to send surfers to.
- offer_description - (optional) Description of offer.
- date_live - (optional) Date when offer should be shown to affiliates. Defaults to now.
- date_expire - (optional) Date when offer should stop being shown to affiliates and redirect if configured. Defaults to never.
- expire_offer - (optional) Offer ID to send traffic after the expiration date of the offer.
- expire_url - (optional) URL to send traffic after the expiration date of the offer.
- hidden - (optional) If set to '1', Offerit will hide the offer from affiliates. Defaults to '0'.
- no_personal_member_info - (optional) If set to '1', Offerit will not store personal customer information. Defaults to '0'.
- remove_ocode - (optional) If set to '1', Offerit code will not be passed along to the landing page through tracking links. Defaults to '0'.
- offer_group_id - (optional) Offer Group ID to place this offer into.
- offer_thumb - (optional) URL of image to save as a thumbnail for the offer.
- marketing_type - (optional) A comma separated list of marketing type IDs active for this offer.
- category - (optional) A comma separated list of category IDs active for this offer
Join to Hit Threshold Settings:
- admin_threshold_email - (optional) A comma separated list of emails that will be sent an email when the join to hit ratio drops below the threshold.
- mail_threshold - (optional) Subject of the email to be sent out when the join to hit ratio drops below the threshold. Required if you wish to receive the emails.
- join_hit_threshold_hour_to_6 - (optional) This is the join to hit ratio threshold that will be checked between the hours of Midnight and 6 AM. Example: 1:400
- join_hit_threshold_hour_to_12 - (optional) This is the join to hit ratio threshold that will be checked between the hours of 6 AM and Noon. Example: 1:400
- join_hit_threshold_hour_to_18 - (optional) This is the join to hit ratio threshold that will be checked between the hours of Noon and 6 PM. Example: 1:400
- join_hit_threshold_hour_to_24 - (optional) This is the join to hit ratio threshold that will be checked between the hours of 6 PM and Midnight. Example: 1:400
Advertiser Settings:
- advertiserid - (optional) The advertiser ID this offer should be assigned to.
- cost_type - (optional) Income for advertiser offer. Possible values are:
- conversion - Income will be calculated per conversion. Used with the cost_flat income option.
- sale - Income will be calculated per conversion. Used with the cost_perc income option.
- singleimpression - Income will be calculated per impression. Used with the cost_flat income option.
- click - Income will be calculated per click. Used with the cost_flat income option.
- impression - Income will be calculated per 1,000 impressions. Used with the cost_flat income option.
- cost_flat - (optional) Flat amount received from advertiser action.
- cost_perc - (optional) Percentage amount of transaction received from advertiser action.
- pending - (optional) The pending status of this offer. Only used with advertisers. Possible values are:
- 0 = Active
- 1 = Pending
- 2 = Denied
Commission Settings:
- comm_type - (optional) Commission type. Possible values are:
- 201 = $ per CPA: Pays your affiliates a flat amount per transaction.
- 202 = % of CPS: Pays your affiliates a percentage of the transaction amount.
- 203 = CPM: Pays your affiliates a flat amount for every 1,000 surfers they send.
- 204 = $ per Click: Pays a flat amount per surfer click.
- 205 = Hybrid: If you need to combine multiple types of payment. This is the default commission type selected.
- flat_amount_per_click - (optional) Flat amount to be paid out to affiliate per surfer click.
- flat_amount_per_visitor - (optional) Flat amount paid out to affiliates per visitor (unique click).
- flat_amount_per_conversion - (optional) Flat amount per conversion.
- flat_amount_per_continuity - (optional) Flat amount per continuity.
- percentage_of_customer_conversion - (optional) Percentage of conversion to be paid to affiliates.
- percentage_of_customer_continuity - (optional) Percentage of continuity to be paid to affiliates.
- flat_amount_for_1000_impressions - (optional) Flat amount per 1,000 impressions
- deduct_voids - (optional) If set to '0', Offerit will NOT deduct commissions from affiliates for conversions that end up being voided when this option is enabled. Defaults to '1'.
- hide_conversions - (optional) If set to '1', Offerit will NOT display conversions on the affiliate's stats pages for this offer. This option will not work if this offer pays affiliates on conversions. Defaults to '0'.
- hide_continuities - (optional) If set to '1', Offerit will NOT display continuities on the affiliate's stats pages for this offer. This option will not work if this offer pays affiliates on continuities. Defaults to '0'.
- retro_payout - (optional) If set to '1', Offerit will pay affiliates the continuity commission set at the time of the conversion. Defaults to '0'.
Landing Page Settings:
- landing_page_name - (optional) Name of the landing page. Defaults to 'Default Landing Page'.
- linkdomain - (optional) URL to use as the tracking domain. Defaults to first tracking domain set up within Offerit.
- description - (optional) Landing page description.
- internal_desc - (optional) Internal description of landing page that only admins will see.
- approvalpost - (optional) URL Offerit will post data to when a conversion occurs.
- voidpost - (optional) URL Offerit will post data to when a Customer's transaction is voided.
- userpost - (optional) URL Offerit will post data to verify the Customer's username is valid.
- change_detailspost - (optional) URL Offerit will post data to when a Customer's details are changed.
- void_reversal_post - (optional) URL Offerit will post data to when a Customer's voided transaction is reversed.
- pending_approvalpost - (optional) URL Offerit will post data to when a pending conversion occurs.
- landing_page_language - (optional) Language name the default landing page should be associated with.
- initial_type - (optional) Sets conversion amount passed in as either revenue or gross. Set to '1' for Revenue or '2' for Gross. Defaults to '1' Revenue.
- initial - (optional) Conversion amount of transaction if amount is not passed in on the transaction.
- initial_days - (optional) Amount of days the custom will be active for if not passed in on the transaction.
- rebill_type - (optional) Sets continuity amount passed in as either revenue or gross. Set to '1' for Revenue or '2' for Gross. Defaults to '1' Revenue.
- rebill - (optional) Continuity amount of transaction if amount is not passed in on the transaction.
- rebill_days - (optional) Amount of days the custom will be active for if not passed in on the transaction.
- conversion_type - (optional) Method of tracking conversion. Possible values are:
- iframe = iframes that allow for advance tracking. Default selected.
- image = Image Pixel / HTML
- post = Postback. Server to server postback that can be IP protected.
- postback_ips - (optional) Comma separated list of IPs that are allowed to post conversions. Only used with postback conversion type.
- private - (optional) If set to '1', Offerit will mark offer as private. Private offers must have affiliates manually enrolled to view offer. Defaults to '0'.
- requestable - (optional) If set to '1', Offerit will mark offer as requestable. Affiliates will be able to see offer and request permission to use it. Only available with private offers. Defaults to '0'.
- preview_url - (optional) URL of offer for affiliates to preview without going through any tracking.
- authorized - (optional) List of countries authorized to promote this offer. (NOTE: You only need to use authorized OR unauthorized.)
- unauthorized - (optional) List of countries unauthorized to promote this offer. (NOTE: You only need to use authorized OR unauthorized.)
- landing_page_thumb - (optional) URL of image to save as a thumbnail for the landing page. Defaults to the offer_thumb if set.
Email Settings:
- email_from_customer - (optional) Default from address for customer E-mails.
- email_from_nice_customer - (optional) Default Nice Name for the from address for customer E-mails.
- email_reply_customer - (optional) Default reply to address for customer E-mails.
- email_reply_nice_customer - (optional) Default Nice Name for the reply to address for customer E-mails.
- email_bcc_to_customer - (optional) Default BCC address for customer E-mails.
- email_from_affiliate - (optional) Default from address for affiliate E-mails.
- email_from_nice_affiliate - (optional) Default Nice Name for the from address for affiliate E-mails.
- email_reply_affiliate - (optional) Default reply to address for affiliate E-mails.
- email_reply_nice_affiliate - (optional) Default Nice Name for the reply to address for affiliate E-mails.
- email_bcc_to_affiliate - (optional) Default BCC address for affiliate E-mails.
NuSOAP Example
This example continues from the main article NuSOAP Example:
$values = Array( 'offer_name' => "Test Api Offer", 'url' => 'offerit.com', 'offer_description' => 'Offer Description', 'date_live' => '2013-12-01', 'date_expire' => '2013-12-02', 'pending' => '0', 'hidden' => '1', 'no_personal_member_info' => '1', 'remove_ocode' => '1', 'admin_threshold_email' => 'mike.sopko@offerit.com', 'mail_threshold' => 'email subject', 'join_hit_threshold_hour_to_6' => '1:450', 'join_hit_threshold_hour_to_12' => '1:400', 'join_hit_threshold_hour_to_18' => '1:400', 'join_hit_threshold_hour_to_24' => '1:400', 'expire_offer' => '63', 'expire_url' => 'demo.offerit.com', 'offer_group_id' => '1', 'marketing_type' => '1,3', 'category' => '1,2,5,7', 'comm_type' => '201', 'flat_amount_per_click' => '10', 'flat_amount_per_visitor' => '15', 'flat_amount_per_conversion' => '20', 'flat_amount_per_continuity' => '25', 'percentage_of_customer_conversion_revenue' => '30', 'percentage_of_customer_continuity_revenue' => '35', 'flat_amount_for_1000_impressions' => '40', 'deduct_voids' => '0', 'hide_continuities' => '1', 'hide_conversions' => '1', 'retro_payout' => '1', 'landing_page_name' => 'New API Landing Page', 'linkdomain' => 'demo.offerit.com', 'description' => 'Description', 'internal_desc' => 'Only Admins Can See This', 'denypost' => 'demo.offerit.com/denypost.php', 'approvalpost' => 'demo.offerit.com/denypost.php', 'voidpost' => 'demo.offerit.com/voidpost.php', 'userpost' => 'demo.offerit.com/userpost.php', 'change_detailspost' => 'demo.offerit.com/change_detailspost.php', 'void_reversal_post' => 'demo.offerit.com/void_reversal_post.php', 'pending_approvalpost' => 'demo.offerit.com/pending_approvalpost.php', 'void_reversal_post' => 'demo.offerit.com/void_reversal_post.php', 'preview_url' => 'offerit.com', 'landing_page_language' => 'English', 'initial' => '10.95', 'initial_days' => '20', 'rebill' => '30', 'rebill_days' => '40', 'conversion_type' => 'iframe', 'private' => '1', 'requestable' => '1', 'initial_type' => '1', 'rebill_type' => '1', 'postback_ips' => '127.0.0.1, 1.1.2.1, 123.123.123.123', 'authorized' => 'US,BG,UK', 'unauthorized' => '', 'offer_thumb' => 'http://demo.offerit.com/offerit_images/about_16.gif', 'landing_page_thumb' => 'http://demo.offerit.com/offerit_images/user_16.gif', 'email_from_customer' => 'customer@offerit.com', 'email_from_nice_customer' => 'Customer Offerit Email', 'email_reply_customer' => 'reply@offerit.com', 'email_reply_nice_customer' => 'Customer Reply Email', 'email_bcc_to_customer' => 'bcc@offerit.com', 'email_from_affiliate' => 'affiliate@offerit.com', 'email_from_nice_affiliate' => 'Affiliate Offerit Email', 'email_reply_affiliate' => 'reply@offerit.com', 'email_reply_nice_affiliate' => 'Affiliate Reply Email', 'email_bcc_to_affiliate' => 'bcc@offerit.com', 'advertiserid' => '46', 'affiliate_payout' => '1', 'cost_type' => 'click', 'cost_flat' => '1', 'cost_perc' => '20', ); $result = $client->call('api_add_offer', $values, 'offeritapiadmin_wsdl');
Sample Output
on success: SUCCESS on error: ERROR: error message