Difference between revisions of "Offerit API Get Profit Loss Report"
From Offerit
OfferitSopko (talk | contribs) (Created page with "{{Offerit Manual | show_api_admin_section = true }} This functions allows for you to grab all the details for the profit and loss report remotely. The get_profit_loss_report acc...") |
(No difference)
|
Revision as of 08:21, 20 September 2013
This functions allows for you to grab all the details for the profit and loss report remotely. The get_profit_loss_report accepts the following parameters:
- view - The breakdown of the report to display. The possible options are:
- period
- month
- year
- offer_group
- landing_page
- offer
- subid1
- subid2
- login
- adtool
- demographic
- params - Parameters for the report. Must be an array and may contain any of the following:
- period - Which period of time to select data for. The following are the allowed periods parameters for Offerit:
- 0 - Current Period
- 1 - Last Period
- 2 - Today
- 3 - Yesterday
- 4 - Past Week
- 5 - Past Month
- 6 - Past Year
- 7 - All Time
- 8 - Free Form Date
- start - Free Form start date for stats. Used when period is not sent or set to 8
- end - Free Form end date for stats. Used when period is not sent or set to 8
- acct_rep - View the profit and loss report as an account rep. Will only see stats for the affiliates assigned to the account rep.
- filter_loginid - Only see stats for the specific login ID passed in.
- filter_campaignid - Only see stats for the specific campaign ID for the affiliate. This parameter can only be used if filter_loginid is passed in.
- filter_offerid - Only see stats for the specific Offer ID passed in.
- filter_landing_pageid - Only see stats for the specific Landing Page ID passed in.
- filter_adtoolid - Only see stats for the specific Creative ID passed in.
- filter_offeritcode - Breakdown the Offerit code and only view stats associated with the Offerit code.
- no_inhouse - Remove in-house traffic from the returned report.
- no_typein - Remove type-in traffic from the returned report.
- period - Which period of time to select data for. The following are the allowed periods parameters for Offerit:
NuSOAP Example
This example continues from the main article NuSOAP Example:
$function = 'get_profit_loss_report'; $values = Array( 'view' => 'year', 'params' => Array( 'period' => 7, ), ); $result = $client->call($function, $values, 'offeritapiadmin_wsdl');
Sample Output
Array ( [total] => Array ( [breakdown] => year [row] => Array ( [initial] => 389 [initial_amount] => 1373187 [charges] => 19200 [affiliate_payout] => 100430 [payout] => 100430 [referral_payout] => 0 [account_rep_payout] => 0 [partner_payout] => 0 [byoa_payout] => 0 [promotional_payout] => 0 [join_profit] => 3779173 [rebill] => 46 [rebill_amount] => 120033 [recurring] => 56 [recurring_profit] => 121573 [wm_join] => 29 [wm_join_referral_payout] => 0 [void] => 77 [void_amount] => -73703 [refunds] => 51 [refund_loss] => -38645 [void_reversal] => 36 [void_reversal_amount] => 37908 [advertiser_initial] => 272 [advertiser_initial_amount] => 2276720 [impression] => 18993 [visitor] => 7969 [chargeback] => 10 [chargeback_amount] => -2850 [phone_call] => 30 [phone_call_amount] => 0 [phone_conversion] => 10 [phone_conversion_amount] => 0 [joins_amount] => 19593 [conversion] => 0 [conversion_amount] => 0 [recurring_count] => 0 [recurring_amount] => 0 [advertiser_income_amount] => 0 [seconds_amount] => 0 [credit] => 0 [credit_amount] => 0 [insufficient_funds] => 0 [insufficient_funds_amount] => 0 [credit_reversal] => 0 [credit_reversal_amount] => 0 [chargeback_reversal] => 0 [chargeback_reversal_amount] => 0 [insufficient_funds_reversal] => 0 [insufficient_funds_reversal_amount] => 0 [reversals] => 0 [reversal_profit] => 0 [tier_adjustment_payout] => 0 [correction_payout] => 0 [custom_income] => 0 ) ) [rows] => Array ( [0] => Array ( [break] => 1293858000 [stats] => Array ( [impression] => 0 [visitor] => 0 [name] => 1293858000 [initial] => 0 [initial_amount] => 0 [advertiser_initial] => 0 [advertiser_initial_amount] => 0 [join_profit] => 0 [joins_amount] => 0 [phone_call] => 0 [phone_call_amount] => 0 [phone_conversion] => 0 [phone_conversion_amount] => 0 [wm_join] => 0 [conversion] => 0 [conversion_amount] => 0 [rebill] => 0 [rebill_amount] => 0 [recurring_count] => 0 [recurring_amount] => 0 [recurring] => 0 [recurring_profit] => 0 [advertiser_income_amount] => 0 [seconds_amount] => 0 [void] => 0 [void_amount] => 0 [credit] => 0 [credit_amount] => 0 [chargeback] => 0 [chargeback_amount] => 0 [insufficient_funds] => 0 [insufficient_funds_amount] => 0 [refunds] => 0 [refund_loss] => 0 [void_reversal] => 0 [void_reversal_amount] => 0 [credit_reversal] => 0 [credit_reversal_amount] => 0 [chargeback_reversal] => 0 [chargeback_reversal_amount] => 0 [insufficient_funds_reversal] => 0 [insufficient_funds_reversal_amount] => 0 [reversals] => 0 [reversal_profit] => 0 [payout] => 0 [affiliate_payout] => 0 [wm_join_referral_payout] => 0 [referral_payout] => 0 [account_rep_payout] => 0 [partner_payout] => 0 [byoa_payout] => 0 [promotional_payout] => 0 [tier_adjustment_payout] => 0 [correction_payout] => 0 [charges] => 0 [custom_income] => 0 ) ) ) )