google-adwords-api 0.4.0 → 0.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/ChangeLog +9 -0
- data/README +26 -10
- data/Rakefile +1 -1
- data/examples/v200909/add_ad_group.rb +2 -2
- data/examples/v200909/add_ads.rb +4 -4
- data/examples/v200909/add_campaign.rb +2 -2
- data/examples/v200909/check_campaigns.rb +4 -4
- data/examples/v201003/add_ad_group.rb +2 -2
- data/examples/v201003/add_ads.rb +6 -6
- data/examples/v201003/add_campaign.rb +2 -2
- data/examples/v201003/add_keywords_performance_report_definition.rb +2 -2
- data/examples/v201003/check_campaigns.rb +4 -4
- data/examples/v201008/add_ad_group.rb +2 -2
- data/examples/v201008/add_ads.rb +7 -7
- data/examples/v201008/add_campaign.rb +2 -2
- data/examples/v201008/add_experiment.rb +5 -5
- data/examples/v201008/add_keywords_performance_report_definition.rb +2 -2
- data/examples/v201008/add_user_list.rb +2 -2
- data/examples/v201008/check_campaigns.rb +4 -4
- data/examples/v201008/get_account_hierarchy.rb +8 -11
- data/examples/v201101/add_ad_group.rb +2 -2
- data/examples/v201101/add_ads.rb +6 -6
- data/examples/v201101/add_campaign.rb +2 -2
- data/examples/v201101/add_conversion.rb +4 -4
- data/examples/v201101/add_experiment.rb +5 -5
- data/examples/v201101/add_keywords_performance_report_definition.rb +2 -2
- data/examples/v201101/add_user_list.rb +3 -3
- data/examples/v201101/check_campaigns.rb +4 -4
- data/examples/v201101/get_account_hierarchy.rb +7 -9
- data/examples/v201109/add_ad_extension_override.rb +82 -0
- data/examples/v201109/add_ad_group.rb +89 -0
- data/examples/v201109/add_ad_group_criteria.rb +109 -0
- data/examples/v201109/add_ads.rb +174 -0
- data/examples/v201109/add_campaign.rb +99 -0
- data/examples/v201109/add_campaign_ad_extension.rb +121 -0
- data/examples/v201109/add_campaign_targeting_criteria.rb +102 -0
- data/examples/{v201101/add_mcc_report_definition.rb → v201109/add_conversion.rb} +26 -28
- data/examples/v201109/add_experiment.rb +153 -0
- data/examples/v201109/add_negative_campaign_criterion.rb +87 -0
- data/examples/v201109/add_user_list.rb +113 -0
- data/examples/v201109/check_campaigns.rb +123 -0
- data/examples/v201109/delete_ad.rb +85 -0
- data/examples/v201109/delete_ad_group.rb +77 -0
- data/examples/v201109/delete_ad_group_criterion.rb +86 -0
- data/examples/v201109/delete_bulk_mutate_job.rb +87 -0
- data/examples/v201109/delete_campaign.rb +78 -0
- data/examples/v201109/delete_experiment.rb +78 -0
- data/examples/v201109/delete_user_list.rb +78 -0
- data/examples/v201109/download_adhoc_report.rb +79 -0
- data/examples/v201109/download_report.rb +67 -0
- data/examples/v201109/get_account_hierarchy.rb +93 -0
- data/examples/v201109/get_ad_group_bid_landscape.rb +94 -0
- data/examples/v201109/get_all_account_changes.rb +137 -0
- data/examples/v201109/get_all_active_ad_group_criteria.rb +98 -0
- data/examples/v201109/get_all_ad_extension_overrides.rb +82 -0
- data/examples/v201109/get_all_ad_group_criteria.rb +90 -0
- data/examples/v201109/get_all_ad_groups.rb +85 -0
- data/examples/v201109/get_all_ad_params.rb +86 -0
- data/examples/v201109/get_all_ads.rb +90 -0
- data/examples/v201109/get_all_campaign_ad_extensions.rb +87 -0
- data/examples/v201109/get_all_campaign_targets.rb +74 -0
- data/examples/v201109/get_all_campaigns.rb +77 -0
- data/examples/v201109/get_all_carriers.rb +72 -0
- data/examples/v201109/get_all_conversions.rb +79 -0
- data/examples/v201109/get_all_disapproved_ads.rb +93 -0
- data/examples/v201109/get_all_experiments.rb +89 -0
- data/examples/v201109/get_all_images.rb +82 -0
- data/examples/v201109/get_all_languages.rb +73 -0
- data/examples/v201109/get_all_paused_campaigns.rb +83 -0
- data/examples/v201109/get_all_report_definitions.rb +75 -0
- data/examples/v201109/get_all_user_lists.rb +78 -0
- data/examples/v201109/get_all_videos.rb +78 -0
- data/examples/v201109/get_bulk_mutate_job.rb +97 -0
- data/examples/v201109/get_campaign_alerts.rb +95 -0
- data/examples/v201109/get_client_customer_id.rb +87 -0
- data/examples/v201109/get_conversion_optimizer_eligibility.rb +93 -0
- data/examples/v201109/get_criterion_bid_landscape.rb +93 -0
- data/examples/v201109/get_geo_location_info.rb +99 -0
- data/examples/v201109/get_keyword_opportunities.rb +95 -0
- data/examples/v201109/get_location_criteria.rb +103 -0
- data/examples/v201109/get_method_cost.rb +87 -0
- data/examples/v201109/get_operation_count.rb +79 -0
- data/examples/v201109/get_related_keywords.rb +108 -0
- data/examples/v201109/get_related_placements.rb +107 -0
- data/examples/v201109/get_report_fields.rb +72 -0
- data/examples/v201109/get_total_usage_units_per_month.rb +74 -0
- data/examples/v201109/get_traffic_estimates.rb +129 -0
- data/examples/v201109/get_unit_count.rb +81 -0
- data/examples/v201109/handle_partial_failures.rb +127 -0
- data/examples/v201109/handle_policy_violation_error.rb +138 -0
- data/examples/v201109/handle_second_factor.rb +87 -0
- data/examples/v201109/oauth_handling.rb +95 -0
- data/examples/v201109/perform_bulk_mutate_job.rb +212 -0
- data/examples/v201109/perform_mutate_job.rb +177 -0
- data/examples/v201109/promote_experiment.rb +79 -0
- data/examples/v201109/set_ad_params.rb +115 -0
- data/examples/v201109/update_ad.rb +86 -0
- data/examples/v201109/update_ad_group.rb +81 -0
- data/examples/v201109/update_ad_group_criterion.rb +99 -0
- data/examples/v201109/update_campaign.rb +84 -0
- data/examples/v201109/update_conversion.rb +87 -0
- data/examples/v201109/update_user_list.rb +82 -0
- data/examples/v201109/upload_image.rb +90 -0
- data/lib/adwords_api.rb +54 -50
- data/lib/adwords_api/api_config.rb +70 -14
- data/lib/adwords_api/credential_handler.rb +32 -13
- data/lib/adwords_api/errors.rb +12 -0
- data/lib/adwords_api/extensions.rb +8 -118
- data/lib/adwords_api/report_utils.rb +198 -0
- data/lib/adwords_api/utils.rb +5 -2
- data/lib/adwords_api/v13/account_service.rb +11 -11
- data/lib/adwords_api/v13/account_service_registry.rb +5 -3
- data/lib/adwords_api/v13/report_service.rb +15 -15
- data/lib/adwords_api/v13/report_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/ad_extension_override_service.rb +5 -5
- data/lib/adwords_api/v200909/ad_extension_override_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/ad_group_ad_service.rb +5 -5
- data/lib/adwords_api/v200909/ad_group_ad_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/ad_group_criterion_service.rb +5 -5
- data/lib/adwords_api/v200909/ad_group_criterion_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/ad_group_service.rb +5 -5
- data/lib/adwords_api/v200909/ad_group_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/ad_param_service.rb +5 -5
- data/lib/adwords_api/v200909/ad_param_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/bulk_mutate_job_service.rb +5 -5
- data/lib/adwords_api/v200909/bulk_mutate_job_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/campaign_ad_extension_service.rb +5 -5
- data/lib/adwords_api/v200909/campaign_ad_extension_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/campaign_criterion_service.rb +5 -5
- data/lib/adwords_api/v200909/campaign_criterion_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/campaign_service.rb +5 -5
- data/lib/adwords_api/v200909/campaign_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/campaign_target_service.rb +5 -5
- data/lib/adwords_api/v200909/campaign_target_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/geo_location_service.rb +3 -3
- data/lib/adwords_api/v200909/geo_location_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/info_service.rb +3 -3
- data/lib/adwords_api/v200909/info_service_registry.rb +5 -3
- data/lib/adwords_api/v200909/targeting_idea_service.rb +5 -5
- data/lib/adwords_api/v200909/targeting_idea_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/ad_extension_override_service.rb +5 -5
- data/lib/adwords_api/v201003/ad_extension_override_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/ad_group_ad_service.rb +5 -5
- data/lib/adwords_api/v201003/ad_group_ad_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/ad_group_criterion_service.rb +5 -5
- data/lib/adwords_api/v201003/ad_group_criterion_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/ad_group_service.rb +5 -5
- data/lib/adwords_api/v201003/ad_group_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/ad_param_service.rb +5 -5
- data/lib/adwords_api/v201003/ad_param_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/bid_landscape_service.rb +3 -3
- data/lib/adwords_api/v201003/bid_landscape_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/bulk_mutate_job_service.rb +5 -5
- data/lib/adwords_api/v201003/bulk_mutate_job_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/campaign_ad_extension_service.rb +5 -5
- data/lib/adwords_api/v201003/campaign_ad_extension_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/campaign_criterion_service.rb +5 -5
- data/lib/adwords_api/v201003/campaign_criterion_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/campaign_service.rb +5 -5
- data/lib/adwords_api/v201003/campaign_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/campaign_target_service.rb +5 -5
- data/lib/adwords_api/v201003/campaign_target_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/geo_location_service.rb +3 -3
- data/lib/adwords_api/v201003/geo_location_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/info_service.rb +3 -3
- data/lib/adwords_api/v201003/info_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/media_service.rb +5 -5
- data/lib/adwords_api/v201003/media_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/report_definition_service.rb +7 -7
- data/lib/adwords_api/v201003/report_definition_service_registry.rb +5 -3
- data/lib/adwords_api/v201003/targeting_idea_service.rb +5 -5
- data/lib/adwords_api/v201003/targeting_idea_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/ad_extension_override_service.rb +5 -5
- data/lib/adwords_api/v201008/ad_extension_override_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/ad_group_ad_service.rb +5 -5
- data/lib/adwords_api/v201008/ad_group_ad_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/ad_group_criterion_service.rb +5 -5
- data/lib/adwords_api/v201008/ad_group_criterion_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/ad_group_service.rb +5 -5
- data/lib/adwords_api/v201008/ad_group_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/ad_param_service.rb +5 -5
- data/lib/adwords_api/v201008/ad_param_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/alert_service.rb +3 -3
- data/lib/adwords_api/v201008/alert_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/bid_landscape_service.rb +3 -3
- data/lib/adwords_api/v201008/bid_landscape_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/bulk_mutate_job_service.rb +5 -5
- data/lib/adwords_api/v201008/bulk_mutate_job_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/campaign_ad_extension_service.rb +5 -5
- data/lib/adwords_api/v201008/campaign_ad_extension_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/campaign_criterion_service.rb +5 -5
- data/lib/adwords_api/v201008/campaign_criterion_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/campaign_service.rb +5 -5
- data/lib/adwords_api/v201008/campaign_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/campaign_target_service.rb +5 -5
- data/lib/adwords_api/v201008/campaign_target_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/customer_sync_service.rb +3 -3
- data/lib/adwords_api/v201008/customer_sync_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/experiment_service.rb +5 -5
- data/lib/adwords_api/v201008/experiment_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/geo_location_service.rb +3 -3
- data/lib/adwords_api/v201008/geo_location_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/info_service.rb +3 -3
- data/lib/adwords_api/v201008/info_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/media_service.rb +5 -5
- data/lib/adwords_api/v201008/media_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/report_definition_service.rb +7 -7
- data/lib/adwords_api/v201008/report_definition_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/serviced_account_service.rb +3 -3
- data/lib/adwords_api/v201008/serviced_account_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/targeting_idea_service.rb +5 -5
- data/lib/adwords_api/v201008/targeting_idea_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/traffic_estimator_service.rb +3 -3
- data/lib/adwords_api/v201008/traffic_estimator_service_registry.rb +5 -3
- data/lib/adwords_api/v201008/user_list_service.rb +5 -5
- data/lib/adwords_api/v201008/user_list_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/ad_extension_override_service.rb +5 -5
- data/lib/adwords_api/v201101/ad_extension_override_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/ad_group_ad_service.rb +5 -5
- data/lib/adwords_api/v201101/ad_group_ad_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/ad_group_criterion_service.rb +5 -5
- data/lib/adwords_api/v201101/ad_group_criterion_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/ad_group_service.rb +5 -5
- data/lib/adwords_api/v201101/ad_group_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/ad_param_service.rb +5 -5
- data/lib/adwords_api/v201101/ad_param_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/alert_service.rb +3 -3
- data/lib/adwords_api/v201101/alert_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/bulk_mutate_job_service.rb +5 -5
- data/lib/adwords_api/v201101/bulk_mutate_job_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/bulk_opportunity_service.rb +3 -3
- data/lib/adwords_api/v201101/bulk_opportunity_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/campaign_ad_extension_service.rb +5 -5
- data/lib/adwords_api/v201101/campaign_ad_extension_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/campaign_criterion_service.rb +5 -5
- data/lib/adwords_api/v201101/campaign_criterion_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/campaign_service.rb +5 -5
- data/lib/adwords_api/v201101/campaign_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/campaign_target_service.rb +5 -5
- data/lib/adwords_api/v201101/campaign_target_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/conversion_tracker_service.rb +5 -5
- data/lib/adwords_api/v201101/conversion_tracker_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/customer_sync_service.rb +3 -3
- data/lib/adwords_api/v201101/customer_sync_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/data_service.rb +5 -5
- data/lib/adwords_api/v201101/data_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/experiment_service.rb +5 -5
- data/lib/adwords_api/v201101/experiment_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/geo_location_service.rb +3 -3
- data/lib/adwords_api/v201101/geo_location_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/info_service.rb +3 -3
- data/lib/adwords_api/v201101/info_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/media_service.rb +5 -5
- data/lib/adwords_api/v201101/media_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/report_definition_service.rb +7 -15
- data/lib/adwords_api/v201101/report_definition_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/serviced_account_service.rb +3 -3
- data/lib/adwords_api/v201101/serviced_account_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/targeting_idea_service.rb +5 -5
- data/lib/adwords_api/v201101/targeting_idea_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/traffic_estimator_service.rb +3 -3
- data/lib/adwords_api/v201101/traffic_estimator_service_registry.rb +5 -3
- data/lib/adwords_api/v201101/user_list_service.rb +5 -5
- data/lib/adwords_api/v201101/user_list_service_registry.rb +5 -3
- data/lib/adwords_api/v201109/ad_extension_override_service.rb +36 -0
- data/lib/adwords_api/v201109/ad_extension_override_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/ad_group_ad_service.rb +36 -0
- data/lib/adwords_api/v201109/ad_group_ad_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/ad_group_criterion_service.rb +36 -0
- data/lib/adwords_api/v201109/ad_group_criterion_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/ad_group_service.rb +36 -0
- data/lib/adwords_api/v201109/ad_group_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/ad_param_service.rb +36 -0
- data/lib/adwords_api/v201109/ad_param_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/alert_service.rb +32 -0
- data/lib/adwords_api/v201109/alert_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/bulk_mutate_job_service.rb +36 -0
- data/lib/adwords_api/v201109/bulk_mutate_job_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/bulk_opportunity_service.rb +32 -0
- data/lib/adwords_api/v201109/bulk_opportunity_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/campaign_ad_extension_service.rb +36 -0
- data/lib/adwords_api/v201109/campaign_ad_extension_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/campaign_criterion_service.rb +36 -0
- data/lib/adwords_api/v201109/campaign_criterion_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/campaign_service.rb +36 -0
- data/lib/adwords_api/v201109/campaign_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/campaign_target_service.rb +36 -0
- data/lib/adwords_api/v201109/campaign_target_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/constant_data_service.rb +36 -0
- data/lib/adwords_api/v201109/constant_data_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/conversion_tracker_service.rb +36 -0
- data/lib/adwords_api/v201109/conversion_tracker_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/customer_sync_service.rb +32 -0
- data/lib/adwords_api/v201109/customer_sync_service_registry.rb +45 -0
- data/lib/adwords_api/v201109/data_service.rb +36 -0
- data/lib/adwords_api/v201109/data_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/experiment_service.rb +36 -0
- data/lib/adwords_api/v201109/experiment_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/geo_location_service.rb +32 -0
- data/lib/adwords_api/v201109/geo_location_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/info_service.rb +32 -0
- data/lib/adwords_api/v201109/info_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/location_criterion_service.rb +32 -0
- data/lib/adwords_api/v201109/location_criterion_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/media_service.rb +36 -0
- data/lib/adwords_api/v201109/media_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/mutate_job_service.rb +40 -0
- data/lib/adwords_api/v201109/mutate_job_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/report_definition_service.rb +45 -0
- data/lib/adwords_api/v201109/report_definition_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/serviced_account_service.rb +32 -0
- data/lib/adwords_api/v201109/serviced_account_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/targeting_idea_service.rb +36 -0
- data/lib/adwords_api/v201109/targeting_idea_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/traffic_estimator_service.rb +32 -0
- data/lib/adwords_api/v201109/traffic_estimator_service_registry.rb +44 -0
- data/lib/adwords_api/v201109/user_list_service.rb +36 -0
- data/lib/adwords_api/v201109/user_list_service_registry.rb +44 -0
- data/test/bugs/test_issue_00000031.rb +78 -0
- metadata +467 -342
- data/examples/v201101/download_mcc_report.rb +0 -113
- data/examples/v201101/download_mcc_report_as_file.rb +0 -114
- data/lib/adwords_api/v13/traffic_estimator_service.rb +0 -44
- data/lib/adwords_api/v13/traffic_estimator_service_registry.rb +0 -39
|
@@ -0,0 +1,198 @@
|
|
|
1
|
+
#!/usr/bin/ruby
|
|
2
|
+
#
|
|
3
|
+
# Author:: api.dklimkin@gmail.com (Danial Klimkin)
|
|
4
|
+
#
|
|
5
|
+
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
6
|
+
#
|
|
7
|
+
# License:: Licensed under the Apache License, Version 2.0 (the "License");
|
|
8
|
+
# you may not use this file except in compliance with the License.
|
|
9
|
+
# You may obtain a copy of the License at
|
|
10
|
+
#
|
|
11
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
12
|
+
#
|
|
13
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
14
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
15
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
16
|
+
# implied.
|
|
17
|
+
# See the License for the specific language governing permissions and
|
|
18
|
+
# limitations under the License.
|
|
19
|
+
#
|
|
20
|
+
# Contains utility methods specific to reporting.
|
|
21
|
+
|
|
22
|
+
require 'gyoku'
|
|
23
|
+
|
|
24
|
+
require 'adwords_api/errors'
|
|
25
|
+
|
|
26
|
+
module AdwordsApi
|
|
27
|
+
class ReportUtils
|
|
28
|
+
# Default constructor.
|
|
29
|
+
#
|
|
30
|
+
# Args:
|
|
31
|
+
# - api: AdwordsApi object
|
|
32
|
+
# - version: API version to use
|
|
33
|
+
#
|
|
34
|
+
def initialize(api, version)
|
|
35
|
+
@api, @version = api, version
|
|
36
|
+
end
|
|
37
|
+
|
|
38
|
+
# Downloads and returns a report.
|
|
39
|
+
#
|
|
40
|
+
# Args:
|
|
41
|
+
# - report_definition: definition of the report in XML text or hash
|
|
42
|
+
#
|
|
43
|
+
# Returns:
|
|
44
|
+
# - report body
|
|
45
|
+
#
|
|
46
|
+
# Raises:
|
|
47
|
+
# - AdwordsApi::Errors::InvalidReportDefinitionError if the report
|
|
48
|
+
# definition is invalid
|
|
49
|
+
# - AdwordsApi::Errors::ReportError if server-side error occurred
|
|
50
|
+
#
|
|
51
|
+
def download_report(report_definition)
|
|
52
|
+
return get_report_response(report_definition).body
|
|
53
|
+
end
|
|
54
|
+
|
|
55
|
+
# Downloads a report and saves it to a file.
|
|
56
|
+
#
|
|
57
|
+
# Args:
|
|
58
|
+
# - report_definition: definition of the report in XML text or hash
|
|
59
|
+
# - path: path to save report to
|
|
60
|
+
#
|
|
61
|
+
# Returns:
|
|
62
|
+
# - nil
|
|
63
|
+
#
|
|
64
|
+
# Raises:
|
|
65
|
+
# - AdwordsApi::Errors::InvalidReportDefinitionError if the report
|
|
66
|
+
# definition is invalid
|
|
67
|
+
# - AdwordsApi::Errors::ReportError if server-side error occurred
|
|
68
|
+
#
|
|
69
|
+
def download_report_as_file(report_definition, path)
|
|
70
|
+
report_body = download_report(report_definition)
|
|
71
|
+
save_to_file(report_body, path)
|
|
72
|
+
return nil
|
|
73
|
+
end
|
|
74
|
+
|
|
75
|
+
private
|
|
76
|
+
|
|
77
|
+
# Minimal set of required fields for report definition.
|
|
78
|
+
REQUIRED_FIELDS = [:selector, :report_name, :report_type, :date_range_type]
|
|
79
|
+
|
|
80
|
+
# Definition fields have to be in particular order in the XML. Here is its
|
|
81
|
+
# specification.
|
|
82
|
+
REPORT_DEFINITION_ORDER = {
|
|
83
|
+
:root => [:selector, :report_name, :report_type, :date_range_type,
|
|
84
|
+
:download_format, :include_zero_impressions],
|
|
85
|
+
:selector => [:fields, :predicates, :date_range],
|
|
86
|
+
:predicates => [:field, :operator, :values]
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
# Send POST request for a report and returns Response object.
|
|
90
|
+
def get_report_response(report_definition)
|
|
91
|
+
definition_text = get_report_definition_text(report_definition)
|
|
92
|
+
data = {"__rdxml" => definition_text}
|
|
93
|
+
url = @api.api_config.adhoc_report_download_url(
|
|
94
|
+
@api.config.read('service.environment'), @version)
|
|
95
|
+
headers = get_report_request_headers()
|
|
96
|
+
response = AdsCommon::Http.post_response(url, data, @api.config, headers)
|
|
97
|
+
check_for_errors(response)
|
|
98
|
+
return response
|
|
99
|
+
end
|
|
100
|
+
|
|
101
|
+
# Converts passed object to XML text. Currently support String (no changes)
|
|
102
|
+
# and Hash (renders XML).
|
|
103
|
+
def get_report_definition_text(report_definition)
|
|
104
|
+
return case report_definition
|
|
105
|
+
when String: report_definition
|
|
106
|
+
when Hash: report_definition_to_xml(report_definition)
|
|
107
|
+
else
|
|
108
|
+
raise AdwordsApi::Errors::InvalidReportDefinitionError,
|
|
109
|
+
"Unknown object for report definition: %s" %
|
|
110
|
+
report_definition.class
|
|
111
|
+
end
|
|
112
|
+
end
|
|
113
|
+
|
|
114
|
+
# Prepares headers for report request.
|
|
115
|
+
def get_report_request_headers()
|
|
116
|
+
credentials = @api.credential_handler.credentials
|
|
117
|
+
auth_string = @api.client_login_handler.headers(credentials)[:authToken]
|
|
118
|
+
headers = {
|
|
119
|
+
'Authorization' => "GoogleLogin auth=%s" % auth_string,
|
|
120
|
+
'ClientCustomerId' => credentials[:clientCustomerId],
|
|
121
|
+
'Content-Type' => 'multipart/form-data'
|
|
122
|
+
}
|
|
123
|
+
return headers
|
|
124
|
+
end
|
|
125
|
+
|
|
126
|
+
# Saves raw data to a file.
|
|
127
|
+
def save_to_file(data, path)
|
|
128
|
+
open(path, 'wb') { |file| file.puts(data) } if path
|
|
129
|
+
end
|
|
130
|
+
|
|
131
|
+
# Checks downloaded data for error signature. Raises ReportError if it
|
|
132
|
+
# detects an error.
|
|
133
|
+
def check_for_errors(response)
|
|
134
|
+
# Check for error code.
|
|
135
|
+
unless response.code == 200
|
|
136
|
+
raise AdwordsApi::Errors::ReportError,
|
|
137
|
+
"Report download error occured, http code: %d" % response.code
|
|
138
|
+
end
|
|
139
|
+
# Check for error in body.
|
|
140
|
+
report_body = response.body
|
|
141
|
+
error_message_regex = '^!!!(-?\d+)\|\|\|(-?\d+)\|\|\|(.*)\?\?\?'
|
|
142
|
+
data = report_body.slice(0, 1024)
|
|
143
|
+
matches = data.match(error_message_regex)
|
|
144
|
+
if matches
|
|
145
|
+
message = (matches[3].nil?) ? data : matches[3]
|
|
146
|
+
raise AdwordsApi::Errors::ReportError,
|
|
147
|
+
"Report download error occured: %s" % message
|
|
148
|
+
end
|
|
149
|
+
return nil
|
|
150
|
+
end
|
|
151
|
+
|
|
152
|
+
# Renders a report definition hash into XML text.
|
|
153
|
+
def report_definition_to_xml(report_definition)
|
|
154
|
+
check_report_definition_hash(report_definition)
|
|
155
|
+
add_report_definition_hash_order(report_definition)
|
|
156
|
+
return Gyoku.xml({:report_definition => report_definition})
|
|
157
|
+
end
|
|
158
|
+
|
|
159
|
+
# Checks if the report definition looks correct.
|
|
160
|
+
def check_report_definition_hash(report_definition)
|
|
161
|
+
# Minimal set of fields required.
|
|
162
|
+
REQUIRED_FIELDS.each do |field|
|
|
163
|
+
unless report_definition.include?(field)
|
|
164
|
+
raise AdwordsApi::Errors::InvalidReportDefinitionError,
|
|
165
|
+
"Required field '%s' is missing in the definition" % field
|
|
166
|
+
end
|
|
167
|
+
end
|
|
168
|
+
# Fields list is also required.
|
|
169
|
+
unless report_definition[:selector].include?(:fields)
|
|
170
|
+
raise AdwordsApi::Errors::InvalidReportDefinitionError,
|
|
171
|
+
'Fields list is required'
|
|
172
|
+
end
|
|
173
|
+
# 'Fields' must be an Array.
|
|
174
|
+
unless report_definition[:selector][:fields].kind_of?(Array)
|
|
175
|
+
raise AdwordsApi::Errors::InvalidReportDefinitionError,
|
|
176
|
+
'Fields list must be an array'
|
|
177
|
+
end
|
|
178
|
+
# We should request at least one field.
|
|
179
|
+
if report_definition[:selector][:fields].empty?
|
|
180
|
+
raise AdwordsApi::Errors::InvalidReportDefinitionError,
|
|
181
|
+
'At least one field needs to be requested'
|
|
182
|
+
end
|
|
183
|
+
end
|
|
184
|
+
|
|
185
|
+
# Adds fields order hint to generator based on specification.
|
|
186
|
+
def add_report_definition_hash_order(node, name = :root)
|
|
187
|
+
def_order = REPORT_DEFINITION_ORDER[name]
|
|
188
|
+
var_order = def_order.reject {|field| !node.include?(field)}
|
|
189
|
+
node.keys.each do |key|
|
|
190
|
+
if node[key].is_a?(Hash) and REPORT_DEFINITION_ORDER.include?(key)
|
|
191
|
+
add_report_definition_hash_order(node[key], key)
|
|
192
|
+
end
|
|
193
|
+
end
|
|
194
|
+
node[:order!] = var_order
|
|
195
|
+
return nil
|
|
196
|
+
end
|
|
197
|
+
end
|
|
198
|
+
end
|
data/lib/adwords_api/utils.rb
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#!/usr/bin/ruby
|
|
2
2
|
#
|
|
3
|
-
# Author:: sgomes@
|
|
3
|
+
# Author:: api.sgomes@gmail.com (Sérgio Gomes)
|
|
4
4
|
#
|
|
5
5
|
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
6
6
|
#
|
|
@@ -31,7 +31,10 @@ module AdwordsApi
|
|
|
31
31
|
# - hash constructed from map entries
|
|
32
32
|
#
|
|
33
33
|
def self.map(entries)
|
|
34
|
-
return entries.
|
|
34
|
+
return entries.inject({}) do |result, entry|
|
|
35
|
+
result[entry[:key]] = entry[:value]
|
|
36
|
+
result
|
|
37
|
+
end
|
|
35
38
|
end
|
|
36
39
|
|
|
37
40
|
# Returns the source operation index for an error.
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
4
4
|
# License:: Licensed under the Apache License,Version 2.0 (the "License").
|
|
5
5
|
#
|
|
6
|
-
# Code generated by AdsCommon library 0.5.
|
|
6
|
+
# Code generated by AdsCommon library 0.5.2 on 2011-10-20 20:34:46.
|
|
7
7
|
|
|
8
8
|
require 'ads_common/savon_service'
|
|
9
9
|
require 'adwords_api/v13/account_service_registry'
|
|
@@ -15,24 +15,24 @@ module AdwordsApi; module V13; module AccountService
|
|
|
15
15
|
super(api, endpoint, namespace, :v13)
|
|
16
16
|
end
|
|
17
17
|
|
|
18
|
-
def
|
|
19
|
-
return execute_action('
|
|
18
|
+
def get_client_accounts(*args, &block)
|
|
19
|
+
return execute_action('get_client_accounts', args, &block)
|
|
20
20
|
end
|
|
21
21
|
|
|
22
|
-
def
|
|
23
|
-
return execute_action('
|
|
22
|
+
def get_mcc_alerts(*args, &block)
|
|
23
|
+
return execute_action('get_mcc_alerts', args, &block)
|
|
24
24
|
end
|
|
25
25
|
|
|
26
|
-
def
|
|
27
|
-
return execute_action('
|
|
26
|
+
def update_account_info(*args, &block)
|
|
27
|
+
return execute_action('update_account_info', args, &block)
|
|
28
28
|
end
|
|
29
29
|
|
|
30
|
-
def
|
|
31
|
-
return execute_action('
|
|
30
|
+
def get_account_info(*args, &block)
|
|
31
|
+
return execute_action('get_account_info', args, &block)
|
|
32
32
|
end
|
|
33
33
|
|
|
34
|
-
def
|
|
35
|
-
return execute_action('
|
|
34
|
+
def get_client_account_infos(*args, &block)
|
|
35
|
+
return execute_action('get_client_account_infos', args, &block)
|
|
36
36
|
end
|
|
37
37
|
|
|
38
38
|
private
|
|
@@ -3,12 +3,14 @@
|
|
|
3
3
|
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
4
4
|
# License:: Licensed under the Apache License,Version 2.0 (the "License").
|
|
5
5
|
#
|
|
6
|
-
# Code generated by AdsCommon library 0.5.
|
|
6
|
+
# Code generated by AdsCommon library 0.5.2 on 2011-10-20 20:34:46.
|
|
7
|
+
|
|
8
|
+
require 'adwords_api/errors'
|
|
7
9
|
|
|
8
10
|
module AdwordsApi; module V13; module AccountService
|
|
9
11
|
class AccountServiceRegistry
|
|
10
|
-
ACCOUNTSERVICE_METHODS = {:
|
|
11
|
-
ACCOUNTSERVICE_TYPES = {:NetworkTarget=>{:fields=>[{:type=>"NetworkType", :max_occurs=>:unbounded, :name=>:network_types
|
|
12
|
+
ACCOUNTSERVICE_METHODS = {:get_client_accounts=>{:input=>[], :output=>{:fields=>[{:type=>"string", :max_occurs=>:unbounded, :name=>:get_client_accounts_return}], :name=>"get_client_accounts_response"}}, :get_mcc_alerts=>{:input=>[], :output=>{:fields=>[{:type=>"MccAlert", :max_occurs=>:unbounded, :name=>:get_mcc_alerts_return}], :name=>"get_mcc_alerts_response"}}, :update_account_info=>{:input=>[{:type=>"AccountInfo", :name=>:account_info}], :output=>{:fields=>[], :name=>"update_account_info_response"}}, :get_account_info=>{:input=>[], :output=>{:fields=>[{:type=>"AccountInfo", :name=>:get_account_info_return}], :name=>"get_account_info_response"}}, :get_client_account_infos=>{:input=>[], :output=>{:fields=>[{:type=>"ClientAccountInfo", :max_occurs=>:unbounded, :name=>:get_client_account_infos_return}], :name=>"get_client_account_infos_response"}}}
|
|
13
|
+
ACCOUNTSERVICE_TYPES = {:NetworkTarget=>{:fields=>[{:type=>"NetworkType", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:network_types}]}, :MccAlert=>{:fields=>[{:type=>"string", :name=>:client_company_name}, {:type=>"long", :name=>:client_customer_id}, {:type=>"string", :name=>:client_login}, {:type=>"string", :name=>:client_name}, {:type=>"MccAlertPriority", :name=>:priority}, {:type=>"dateTime", :name=>:trigger_time}, {:type=>"MccAlertType", :name=>:type}]}, :Address=>{:fields=>[{:type=>"string", :name=>:address_line1}, {:type=>"string", :name=>:address_line2}, {:type=>"string", :name=>:city}, {:type=>"string", :name=>:company_name}, {:type=>"string", :name=>:country_code}, {:type=>"string", :name=>:email_address}, {:type=>"string", :name=>:fax_number}, {:type=>"string", :name=>:name}, {:type=>"string", :name=>:phone_number}, {:type=>"string", :name=>:postal_code}, {:type=>"string", :name=>:state}]}, :AccountInfo=>{:fields=>[{:type=>"Address", :name=>:billing_address}, {:type=>"string", :name=>:currency_code}, {:type=>"long", :min_occurs=>0, :name=>:customer_id}, {:type=>"NetworkTarget", :name=>:default_network_targeting}, {:type=>"string", :name=>:descriptive_name}, {:type=>"EmailPromotionsPreferences", :name=>:email_promotions_preferences}, {:type=>"string", :name=>:language_preference}, {:type=>"Address", :name=>:primary_address}, {:type=>"string", :name=>:primary_business_category}, {:type=>"long", :min_occurs=>0, :name=>:time_zone_effective_date}, {:type=>"string", :name=>:time_zone_id}]}, :ClientAccountInfo=>{:fields=>[{:type=>"string", :name=>:email_address}, {:type=>"boolean", :name=>:is_customer_manager}]}, :EmailPromotionsPreferences=>{:fields=>[{:type=>"boolean", :name=>:account_performance_enabled}, {:type=>"boolean", :name=>:disapproved_ads_enabled}, {:type=>"boolean", :name=>:market_research_enabled}, {:type=>"boolean", :name=>:newsletter_enabled}, {:type=>"boolean", :name=>:promotions_enabled}]}}
|
|
12
14
|
ACCOUNTSERVICE_NAMESPACES = []
|
|
13
15
|
|
|
14
16
|
def self.get_method_signature(method_name)
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
4
4
|
# License:: Licensed under the Apache License,Version 2.0 (the "License").
|
|
5
5
|
#
|
|
6
|
-
# Code generated by AdsCommon library 0.5.
|
|
6
|
+
# Code generated by AdsCommon library 0.5.2 on 2011-10-20 20:34:44.
|
|
7
7
|
|
|
8
8
|
require 'ads_common/savon_service'
|
|
9
9
|
require 'adwords_api/v13/report_service_registry'
|
|
@@ -16,32 +16,32 @@ module AdwordsApi; module V13; module ReportService
|
|
|
16
16
|
super(api, endpoint, namespace, :v13)
|
|
17
17
|
end
|
|
18
18
|
|
|
19
|
-
def
|
|
20
|
-
return execute_action('
|
|
19
|
+
def get_all_jobs(*args, &block)
|
|
20
|
+
return execute_action('get_all_jobs', args, &block)
|
|
21
21
|
end
|
|
22
22
|
|
|
23
|
-
def
|
|
24
|
-
return execute_action('
|
|
23
|
+
def get_gzip_report_download_url(*args, &block)
|
|
24
|
+
return execute_action('get_gzip_report_download_url', args, &block)
|
|
25
25
|
end
|
|
26
26
|
|
|
27
|
-
def
|
|
28
|
-
return execute_action('
|
|
27
|
+
def schedule_report_job(*args, &block)
|
|
28
|
+
return execute_action('schedule_report_job', args, &block)
|
|
29
29
|
end
|
|
30
30
|
|
|
31
|
-
def
|
|
32
|
-
return execute_action('
|
|
31
|
+
def get_report_job_status(*args, &block)
|
|
32
|
+
return execute_action('get_report_job_status', args, &block)
|
|
33
33
|
end
|
|
34
34
|
|
|
35
|
-
def
|
|
36
|
-
return execute_action('
|
|
35
|
+
def validate_report_job(*args, &block)
|
|
36
|
+
return execute_action('validate_report_job', args, &block)
|
|
37
37
|
end
|
|
38
38
|
|
|
39
|
-
def get_report_download_url(*args)
|
|
40
|
-
return execute_action('get_report_download_url', args)
|
|
39
|
+
def get_report_download_url(*args, &block)
|
|
40
|
+
return execute_action('get_report_download_url', args, &block)
|
|
41
41
|
end
|
|
42
42
|
|
|
43
|
-
def
|
|
44
|
-
return execute_action('
|
|
43
|
+
def delete_report(*args, &block)
|
|
44
|
+
return execute_action('delete_report', args, &block)
|
|
45
45
|
end
|
|
46
46
|
|
|
47
47
|
def download_xml_report(*args)
|
|
@@ -3,12 +3,14 @@
|
|
|
3
3
|
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
4
4
|
# License:: Licensed under the Apache License,Version 2.0 (the "License").
|
|
5
5
|
#
|
|
6
|
-
# Code generated by AdsCommon library 0.5.
|
|
6
|
+
# Code generated by AdsCommon library 0.5.2 on 2011-10-20 20:34:44.
|
|
7
|
+
|
|
8
|
+
require 'adwords_api/errors'
|
|
7
9
|
|
|
8
10
|
module AdwordsApi; module V13; module ReportService
|
|
9
11
|
class ReportServiceRegistry
|
|
10
|
-
REPORTSERVICE_METHODS = {:
|
|
11
|
-
REPORTSERVICE_TYPES = {:DefinedReportJob=>{:fields=>[{:type=>"AdGroupStatus", :max_occurs=>:unbounded, :name=>:ad_group_statuses
|
|
12
|
+
REPORTSERVICE_METHODS = {:get_all_jobs=>{:input=>[], :output=>{:fields=>[{:type=>"ReportJob", :max_occurs=>:unbounded, :name=>:get_all_jobs_return}], :name=>"get_all_jobs_response"}}, :get_gzip_report_download_url=>{:input=>[{:type=>"long", :name=>:report_job_id}], :output=>{:fields=>[{:type=>"string", :name=>:get_gzip_report_download_url_return}], :name=>"get_gzip_report_download_url_response"}}, :schedule_report_job=>{:input=>[{:type=>"ReportJob", :name=>:job}], :output=>{:fields=>[{:type=>"long", :name=>:schedule_report_job_return}], :name=>"schedule_report_job_response"}}, :get_report_job_status=>{:input=>[{:type=>"long", :name=>:report_job_id}], :output=>{:fields=>[{:type=>"ReportJobStatus", :name=>:get_report_job_status_return}], :name=>"get_report_job_status_response"}}, :validate_report_job=>{:input=>[{:type=>"ReportJob", :name=>:job}], :output=>{:fields=>[], :name=>"validate_report_job_response"}}, :get_report_download_url=>{:input=>[{:type=>"long", :name=>:report_job_id}], :output=>{:fields=>[{:type=>"string", :name=>:get_report_download_url_return}], :name=>"get_report_download_url_response"}}, :delete_report=>{:input=>[{:type=>"long", :name=>:report_job_id}], :output=>{:fields=>[], :name=>"delete_report_response"}}}
|
|
13
|
+
REPORTSERVICE_TYPES = {:DefinedReportJob=>{:fields=>[{:type=>"AdGroupStatus", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:ad_group_statuses}, {:type=>"long", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:ad_groups}, {:type=>"AdWordsType", :min_occurs=>0, :name=>:ad_words_type}, {:type=>"string", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:aggregation_types}, {:type=>"CampaignStatus", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:campaign_statuses}, {:type=>"int", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:campaigns}, {:type=>"boolean", :min_occurs=>0, :name=>:include_zero_impression}, {:type=>"KeywordStatus", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:keyword_statuses}, {:type=>"KeywordType", :min_occurs=>0, :name=>:keyword_type}, {:type=>"string", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:keywords}, {:type=>"string", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:selected_columns}, {:type=>"string", :name=>:selected_report_type}], :base=>"ReportJob"}, :ReportJob=>{:fields=>[{:type=>"string", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:client_emails}, {:type=>"boolean", :min_occurs=>0, :name=>:cross_client}, {:type=>"date", :name=>:end_day}, {:type=>"long", :min_occurs=>0, :name=>:id}, {:type=>"string", :min_occurs=>0, :name=>:name}, {:type=>"date", :name=>:start_day}, {:type=>"ReportJobStatus", :min_occurs=>0, :name=>:status}], :abstract=>true}}
|
|
12
14
|
REPORTSERVICE_NAMESPACES = []
|
|
13
15
|
|
|
14
16
|
def self.get_method_signature(method_name)
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
4
4
|
# License:: Licensed under the Apache License,Version 2.0 (the "License").
|
|
5
5
|
#
|
|
6
|
-
# Code generated by AdsCommon library 0.5.
|
|
6
|
+
# Code generated by AdsCommon library 0.5.2 on 2011-10-20 20:39:59.
|
|
7
7
|
|
|
8
8
|
require 'ads_common/savon_service'
|
|
9
9
|
require 'adwords_api/v200909/ad_extension_override_service_registry'
|
|
@@ -15,12 +15,12 @@ module AdwordsApi; module V200909; module AdExtensionOverrideService
|
|
|
15
15
|
super(api, endpoint, namespace, :v200909)
|
|
16
16
|
end
|
|
17
17
|
|
|
18
|
-
def get(*args)
|
|
19
|
-
return execute_action('get', args)
|
|
18
|
+
def get(*args, &block)
|
|
19
|
+
return execute_action('get', args, &block)
|
|
20
20
|
end
|
|
21
21
|
|
|
22
|
-
def mutate(*args)
|
|
23
|
-
return execute_action('mutate', args)
|
|
22
|
+
def mutate(*args, &block)
|
|
23
|
+
return execute_action('mutate', args, &block)
|
|
24
24
|
end
|
|
25
25
|
|
|
26
26
|
private
|
|
@@ -3,12 +3,14 @@
|
|
|
3
3
|
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
4
4
|
# License:: Licensed under the Apache License,Version 2.0 (the "License").
|
|
5
5
|
#
|
|
6
|
-
# Code generated by AdsCommon library 0.5.
|
|
6
|
+
# Code generated by AdsCommon library 0.5.2 on 2011-10-20 20:39:59.
|
|
7
|
+
|
|
8
|
+
require 'adwords_api/errors'
|
|
7
9
|
|
|
8
10
|
module AdwordsApi; module V200909; module AdExtensionOverrideService
|
|
9
11
|
class AdExtensionOverrideServiceRegistry
|
|
10
|
-
ADEXTENSIONOVERRIDESERVICE_METHODS = {:get=>{:input=>[{:type=>"AdExtensionOverrideSelector", :max_occurs=>1, :name=>:selector
|
|
11
|
-
ADEXTENSIONOVERRIDESERVICE_TYPES = {:
|
|
12
|
+
ADEXTENSIONOVERRIDESERVICE_METHODS = {:get=>{:input=>[{:type=>"AdExtensionOverrideSelector", :max_occurs=>1, :min_occurs=>0, :name=>:selector}], :output=>{:fields=>[{:type=>"AdExtensionOverridePage", :max_occurs=>1, :min_occurs=>0, :name=>:rval}], :name=>"get_response"}}, :mutate=>{:input=>[{:type=>"AdExtensionOverrideOperation", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:operations}], :output=>{:fields=>[{:type=>"AdExtensionOverrideReturnValue", :max_occurs=>1, :min_occurs=>0, :name=>:rval}], :name=>"mutate_response"}}}
|
|
13
|
+
ADEXTENSIONOVERRIDESERVICE_TYPES = {:AdExtensionOverridePage=>{:fields=>[{:type=>"AdExtensionOverride", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:entries}], :base=>"Page"}, :LocationOverrideInfo=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:radius}, {:type=>"LocationOverrideInfo.RadiusUnits", :max_occurs=>1, :min_occurs=>0, :name=>:radius_units}]}, :AdExtensionOverrideStats=>{:fields=>[], :base=>"Stats"}, :AdExtensionOverrideReturnValue=>{:fields=>[{:type=>"AdExtensionOverride", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:value}], :base=>"ListReturnValue"}, :Stats=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:start_date}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:end_date}, {:type=>"Stats.Network", :max_occurs=>1, :min_occurs=>0, :name=>:network}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:clicks}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:impressions}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:cost}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:average_position}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:average_cpc}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:average_cpm}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:ctr}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:conversions}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:conversion_rate}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:cost_per_conversion}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:conversions_many_per_click}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:conversion_rate_many_per_click}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:cost_per_conversion_many_per_click}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:stats_type}]}, :DoubleValue=>{:fields=>[{:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:number}], :base=>"NumberValue"}, :ListReturnValue=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:list_return_value_type}], :abstract=>true}, :NumberValue=>{:fields=>[], :abstract=>true, :base=>"ComparableValue"}, :AdExtension=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:id}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:ad_extension_type}]}, :SoapHeader=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:application_token}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:auth_token}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:client_customer_id}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:client_email}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:developer_token}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:user_agent}, {:type=>"boolean", :max_occurs=>1, :min_occurs=>0, :name=>:validate_only}]}, :EntityNotFound=>{:fields=>[{:type=>"EntityNotFound.Reason", :max_occurs=>1, :min_occurs=>0, :name=>:reason}], :base=>"ApiError"}, :Operation=>{:fields=>[{:type=>"Operator", :max_occurs=>1, :min_occurs=>0, :name=>:operator}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:operation_type}], :abstract=>true}, :Address=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:street_address}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:street_address2}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:city_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:province_code}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:province_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:postal_code}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:country_code}]}, :SoapResponseHeader=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:request_id}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:operations}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:response_time}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:units}]}, :GeoPoint=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:latitude_in_micro_degrees}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:longitude_in_micro_degrees}]}, :Page=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:total_num_entries}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:page_type}], :abstract=>true}, :Paging=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:start_index}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:number_results}]}, :OverrideInfo=>{:fields=>[]}, :AdExtensionOverride=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:ad_id}, {:type=>"AdExtension", :max_occurs=>1, :min_occurs=>0, :name=>:ad_extension}, {:type=>"OverrideInfo", :max_occurs=>1, :min_occurs=>0, :name=>:override_info}, {:type=>"AdExtensionOverride.Status", :max_occurs=>1, :min_occurs=>0, :name=>:status}, {:type=>"AdExtensionOverride.ApprovalStatus", :max_occurs=>1, :min_occurs=>0, :name=>:approval_status}, {:type=>"AdExtensionOverrideStats", :max_occurs=>1, :min_occurs=>0, :name=>:stats}]}, :LocationExtension=>{:fields=>[{:type=>"Address", :max_occurs=>1, :min_occurs=>0, :name=>:address}, {:type=>"GeoPoint", :max_occurs=>1, :min_occurs=>0, :name=>:geo_point}, {:type=>"base64Binary", :max_occurs=>1, :min_occurs=>0, :name=>:encoded_location}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:company_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:phone_number}, {:type=>"LocationExtension.Source", :max_occurs=>1, :min_occurs=>0, :name=>:source}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:icon_media_id}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:image_media_id}], :base=>"AdExtension"}, :ComparableValue=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:comparable_value_type}], :abstract=>true}, :AdExtensionOverrideSelector=>{:fields=>[{:type=>"long", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:campaign_ids}, {:type=>"long", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:ad_ids}, {:type=>"long", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:ad_extension_ids}, {:type=>"AdExtensionOverride.Status", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:statuses}, {:type=>"Paging", :max_occurs=>1, :min_occurs=>0, :name=>:paging}]}, :AdExtensionOverrideOperation=>{:fields=>[{:type=>"AdExtensionOverride", :max_occurs=>1, :min_occurs=>0, :name=>:operand}], :base=>"Operation"}, :Money=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:micro_amount}], :base=>"ComparableValue"}, :LongValue=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:number}], :base=>"NumberValue"}}
|
|
12
14
|
ADEXTENSIONOVERRIDESERVICE_NAMESPACES = []
|
|
13
15
|
|
|
14
16
|
def self.get_method_signature(method_name)
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
4
4
|
# License:: Licensed under the Apache License,Version 2.0 (the "License").
|
|
5
5
|
#
|
|
6
|
-
# Code generated by AdsCommon library 0.5.
|
|
6
|
+
# Code generated by AdsCommon library 0.5.2 on 2011-10-20 20:39:33.
|
|
7
7
|
|
|
8
8
|
require 'ads_common/savon_service'
|
|
9
9
|
require 'adwords_api/v200909/ad_group_ad_service_registry'
|
|
@@ -15,12 +15,12 @@ module AdwordsApi; module V200909; module AdGroupAdService
|
|
|
15
15
|
super(api, endpoint, namespace, :v200909)
|
|
16
16
|
end
|
|
17
17
|
|
|
18
|
-
def get(*args)
|
|
19
|
-
return execute_action('get', args)
|
|
18
|
+
def get(*args, &block)
|
|
19
|
+
return execute_action('get', args, &block)
|
|
20
20
|
end
|
|
21
21
|
|
|
22
|
-
def mutate(*args)
|
|
23
|
-
return execute_action('mutate', args)
|
|
22
|
+
def mutate(*args, &block)
|
|
23
|
+
return execute_action('mutate', args, &block)
|
|
24
24
|
end
|
|
25
25
|
|
|
26
26
|
private
|
|
@@ -3,12 +3,14 @@
|
|
|
3
3
|
# Copyright:: Copyright 2011, Google Inc. All Rights Reserved.
|
|
4
4
|
# License:: Licensed under the Apache License,Version 2.0 (the "License").
|
|
5
5
|
#
|
|
6
|
-
# Code generated by AdsCommon library 0.5.
|
|
6
|
+
# Code generated by AdsCommon library 0.5.2 on 2011-10-20 20:39:33.
|
|
7
|
+
|
|
8
|
+
require 'adwords_api/errors'
|
|
7
9
|
|
|
8
10
|
module AdwordsApi; module V200909; module AdGroupAdService
|
|
9
11
|
class AdGroupAdServiceRegistry
|
|
10
|
-
ADGROUPADSERVICE_METHODS = {:get=>{:input=>[{:type=>"AdGroupAdSelector", :max_occurs=>1, :name=>:selector
|
|
11
|
-
ADGROUPADSERVICE_TYPES = {:ListReturnValue=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:list_return_value_type, :min_occurs=>0}], :abstract=>true}, :AdGroupAd=>{:fields=>[{:type=>"long", :max_occurs=>1, :name=>:ad_group_id, :min_occurs=>0}, {:type=>"Ad", :max_occurs=>1, :name=>:ad, :min_occurs=>0}, {:type=>"AdGroupAd.Status", :max_occurs=>1, :name=>:status, :min_occurs=>0}, {:type=>"AdStats", :max_occurs=>1, :name=>:stats, :min_occurs=>0}]}, :ExemptionRequest=>{:fields=>[{:type=>"PolicyViolationKey", :max_occurs=>1, :name=>:key, :min_occurs=>0}]}, :DemographicTarget=>{:fields=>[{:type=>"int", :max_occurs=>1, :name=>:bid_modifier, :min_occurs=>0}], :abstract=>true, :base=>"Target"}, :Video=>{:fields=>[{:type=>"long", :max_occurs=>1, :name=>:duration_millis, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:streaming_url, :min_occurs=>0}, {:type=>"boolean", :max_occurs=>1, :name=>:ready_to_play_on_the_web, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:industry_standard_commercial_identifier, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:advertising_id, :min_occurs=>0}], :base=>"Media"}, :ProximityTarget=>{:fields=>[{:type=>"GeoPoint", :max_occurs=>1, :name=>:geo_point, :min_occurs=>0}, {:type=>"ProximityTarget.DistanceUnits", :max_occurs=>1, :name=>:radius_distance_units, :min_occurs=>0}, {:type=>"double", :max_occurs=>1, :name=>:radius_in_units, :min_occurs=>0}, {:type=>"Address", :max_occurs=>1, :name=>:address, :min_occurs=>0}, {:type=>"boolean", :max_occurs=>1, :name=>:allow_service_of_address, :min_occurs=>0}], :base=>"GeoTarget"}, :Money=>{:fields=>[{:type=>"long", :max_occurs=>1, :name=>:micro_amount, :min_occurs=>0}], :base=>"ComparableValue"}, :Audio=>{:fields=>[{:type=>"long", :max_occurs=>1, :name=>:duration_millis, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:streaming_url, :min_occurs=>0}, {:type=>"boolean", :max_occurs=>1, :name=>:ready_to_play_on_the_web, :min_occurs=>0}], :base=>"Media"}, :TemplateElementField=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:name, :min_occurs=>0}, {:type=>"TemplateElementField.Type", :max_occurs=>1, :name=>:type, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:field_text, :min_occurs=>0}, {:type=>"Media", :max_occurs=>1, :name=>:field_media, :min_occurs=>0}]}, :MobileAd=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:headline, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:description, :min_occurs=>0}, {:type=>"MarkupLanguageType", :max_occurs=>:unbounded, :name=>:markup_languages, :min_occurs=>0}, {:type=>"string", :max_occurs=>:unbounded, :name=>:mobile_carriers, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:business_name, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:country_code, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:phone_number, :min_occurs=>0}], :base=>"Ad"}, :EntityNotFound=>{:fields=>[{:type=>"EntityNotFound.Reason", :max_occurs=>1, :name=>:reason, :min_occurs=>0}], :base=>"ApiError"}, :Operation=>{:fields=>[{:type=>"Operator", :max_occurs=>1, :name=>:operator, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:operation_type, :min_occurs=>0}], :abstract=>true}, :AdGroupAdOperation=>{:fields=>[{:type=>"AdGroupAd", :max_occurs=>1, :name=>:operand, :min_occurs=>0}, {:type=>"ExemptionRequest", :max_occurs=>:unbounded, :name=>:exemption_requests, :min_occurs=>0}], :base=>"Operation"}, :Target=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:target_type, :min_occurs=>0}], :abstract=>true}, :NumberValue=>{:fields=>[], :abstract=>true, :base=>"ComparableValue"}, :NetworkTarget=>{:fields=>[{:type=>"NetworkCoverageType", :max_occurs=>1, :name=>:network_coverage_type, :min_occurs=>0}], :base=>"Target"}, :GenderTarget=>{:fields=>[{:type=>"GenderTarget.Gender", :max_occurs=>1, :name=>:gender, :min_occurs=>0}], :base=>"DemographicTarget"}, :DeprecatedAd=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:name, :min_occurs=>0}, {:type=>"DeprecatedAd.Type", :max_occurs=>1, :name=>:type, :min_occurs=>0}], :base=>"Ad"}, :ImageAd=>{:fields=>[{:type=>"Image", :max_occurs=>1, :name=>:image, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:name, :min_occurs=>0}], :base=>"Ad"}, :PolicyViolationKey=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:policy_name, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:violating_text, :min_occurs=>0}]}, :GeoPoint=>{:fields=>[{:type=>"int", :max_occurs=>1, :name=>:latitude_in_micro_degrees, :min_occurs=>0}, {:type=>"int", :max_occurs=>1, :name=>:longitude_in_micro_degrees, :min_occurs=>0}]}, :AdScheduleTarget=>{:fields=>[{:type=>"DayOfWeek", :max_occurs=>1, :name=>:day_of_week, :min_occurs=>0}, {:type=>"int", :max_occurs=>1, :name=>:start_hour, :min_occurs=>0}, {:type=>"MinuteOfHour", :max_occurs=>1, :name=>:start_minute, :min_occurs=>0}, {:type=>"int", :max_occurs=>1, :name=>:end_hour, :min_occurs=>0}, {:type=>"MinuteOfHour", :max_occurs=>1, :name=>:end_minute, :min_occurs=>0}, {:type=>"double", :max_occurs=>1, :name=>:bid_multiplier, :min_occurs=>0}], :base=>"Target"}, :Page=>{:fields=>[{:type=>"int", :max_occurs=>1, :name=>:total_num_entries, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:page_type, :min_occurs=>0}], :abstract=>true}, :AdGroupAdPage=>{:fields=>[{:type=>"AdGroupAd", :max_occurs=>:unbounded, :name=>:entries, :min_occurs=>0}], :base=>"Page"}, :GeoTarget=>{:fields=>[{:type=>"boolean", :max_occurs=>1, :name=>:excluded, :min_occurs=>0}], :abstract=>true, :base=>"Target"}, :AdUnionId=>{:fields=>[{:type=>"long", :max_occurs=>1, :name=>:id, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:ad_union_id_type, :min_occurs=>0}]}, :StatsSelector=>{:fields=>[{:type=>"DateRange", :max_occurs=>1, :name=>:date_range, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:stats_selector_type, :min_occurs=>0}]}, :OperationAccessDenied=>{:fields=>[{:type=>"OperationAccessDenied.Reason", :max_occurs=>1, :name=>:reason, :min_occurs=>0}], :base=>"ApiError"}, :Dimensions=>{:fields=>[{:type=>"int", :max_occurs=>1, :name=>:width, :min_occurs=>0}, {:type=>"int", :max_occurs=>1, :name=>:height, :min_occurs=>0}]}, :Address=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:street_address, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:street_address2, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:city_name, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:province_code, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:province_name, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:postal_code, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:country_code, :min_occurs=>0}]}, :AdStatsSelector=>{:fields=>[], :base=>"StatsSelector"}, :TemplateElement=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:unique_name, :min_occurs=>0}, {:type=>"TemplateElementField", :max_occurs=>:unbounded, :name=>:fields, :min_occurs=>0}]}, :TempAdUnionId=>{:fields=>[], :base=>"AdUnionId"}, :SoapHeader=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:application_token, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:auth_token, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:client_customer_id, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:client_email, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:developer_token, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:user_agent, :min_occurs=>0}, {:type=>"boolean", :max_occurs=>1, :name=>:validate_only, :min_occurs=>0}]}, :PlatformTarget=>{:fields=>[{:type=>"PlatformType", :max_occurs=>1, :name=>:platform_type, :min_occurs=>0}], :base=>"Target"}, :AgeTarget=>{:fields=>[{:type=>"AgeTarget.Age", :max_occurs=>1, :name=>:age, :min_occurs=>0}], :base=>"DemographicTarget"}, :AdExtensionOverrideStats=>{:fields=>[], :base=>"Stats"}, :AdGroupAdReturnValue=>{:fields=>[{:type=>"AdGroupAd", :max_occurs=>:unbounded, :name=>:value, :min_occurs=>0}], :base=>"ListReturnValue"}, :Media_MediaExtendedCapabilityType_Media_MediaExtendedCapabilityStateMapEntry=>{:fields=>[{:type=>"Media.MediaExtendedCapabilityType", :max_occurs=>1, :name=>:key, :min_occurs=>0}, {:type=>"Media.MediaExtendedCapabilityState", :max_occurs=>1, :name=>:value, :min_occurs=>0}]}, :LanguageTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:language_code, :min_occurs=>0}], :base=>"Target"}, :Image=>{:fields=>[{:type=>"base64Binary", :max_occurs=>1, :name=>:data, :min_occurs=>0}], :base=>"Media"}, :TemplateAd=>{:fields=>[{:type=>"long", :max_occurs=>1, :name=>:template_id, :min_occurs=>0}, {:type=>"AdUnionId", :max_occurs=>1, :name=>:ad_union_id, :min_occurs=>0}, {:type=>"TemplateElement", :max_occurs=>:unbounded, :name=>:template_elements, :min_occurs=>0}, {:type=>"Dimensions", :max_occurs=>1, :name=>:dimensions, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:name, :min_occurs=>0}, {:type=>"int", :max_occurs=>1, :name=>:duration, :min_occurs=>0}], :base=>"Ad"}, :TextAd=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:headline, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:description1, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:description2, :min_occurs=>0}], :base=>"Ad"}, :SoapResponseHeader=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:request_id, :min_occurs=>0}, {:type=>"long", :max_occurs=>1, :name=>:operations, :min_occurs=>0}, {:type=>"long", :max_occurs=>1, :name=>:response_time, :min_occurs=>0}, {:type=>"long", :max_occurs=>1, :name=>:units, :min_occurs=>0}]}, :PolygonTarget=>{:fields=>[{:type=>"GeoPoint", :max_occurs=>:unbounded, :name=>:vertices, :min_occurs=>0}], :base=>"GeoTarget"}, :"PolicyViolationError.Part"=>{:fields=>[{:type=>"int", :max_occurs=>1, :name=>:index, :min_occurs=>0}, {:type=>"int", :max_occurs=>1, :name=>:length, :min_occurs=>0}]}, :LongValue=>{:fields=>[{:type=>"long", :max_occurs=>1, :name=>:number, :min_occurs=>0}], :base=>"NumberValue"}, :CityTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:city_name, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:province_code, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:country_code, :min_occurs=>0}], :base=>"GeoTarget"}, :AdGroupAdCountLimitExceeded=>{:fields=>[], :base=>"EntityCountLimitExceeded"}, :AdGroupAdSelector=>{:fields=>[{:type=>"long", :max_occurs=>:unbounded, :name=>:campaign_ids, :min_occurs=>0}, {:type=>"long", :max_occurs=>:unbounded, :name=>:ad_group_ids, :min_occurs=>0}, {:type=>"long", :max_occurs=>:unbounded, :name=>:ad_ids, :min_occurs=>0}, {:type=>"AdStatsSelector", :max_occurs=>1, :name=>:stats_selector, :min_occurs=>0}, {:type=>"Paging", :max_occurs=>1, :name=>:paging, :min_occurs=>0}]}, :Media=>{:fields=>[{:type=>"long", :max_occurs=>1, :name=>:media_id, :min_occurs=>0}, {:type=>"Media.MediaType", :max_occurs=>1, :name=>:media_type_db, :min_occurs=>0}, {:type=>"long", :max_occurs=>1, :name=>:reference_id, :min_occurs=>0}, {:type=>"Media_Size_DimensionsMapEntry", :max_occurs=>:unbounded, :name=>:dimensions, :min_occurs=>0}, {:type=>"Media_Size_StringMapEntry", :max_occurs=>:unbounded, :name=>:urls, :min_occurs=>0}, {:type=>"Media.MimeType", :max_occurs=>1, :name=>:mime_type, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:source_url, :min_occurs=>0}, {:type=>"Media.MediaSubType", :max_occurs=>1, :name=>:media_sub_type, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:name, :min_occurs=>0}, {:type=>"long", :max_occurs=>1, :name=>:file_size, :min_occurs=>0}, {:type=>"Media_MediaExtendedCapabilityType_Media_MediaExtendedCapabilityStateMapEntry", :max_occurs=>:unbounded, :name=>:extended_capabilities, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:creation_time, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:media_type, :min_occurs=>0}]}, :Stats=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:start_date, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:end_date, :min_occurs=>0}, {:type=>"Stats.Network", :max_occurs=>1, :name=>:network, :min_occurs=>0}, {:type=>"long", :max_occurs=>1, :name=>:clicks, :min_occurs=>0}, {:type=>"long", :max_occurs=>1, :name=>:impressions, :min_occurs=>0}, {:type=>"Money", :max_occurs=>1, :name=>:cost, :min_occurs=>0}, {:type=>"double", :max_occurs=>1, :name=>:average_position, :min_occurs=>0}, {:type=>"Money", :max_occurs=>1, :name=>:average_cpc, :min_occurs=>0}, {:type=>"Money", :max_occurs=>1, :name=>:average_cpm, :min_occurs=>0}, {:type=>"double", :max_occurs=>1, :name=>:ctr, :min_occurs=>0}, {:type=>"long", :max_occurs=>1, :name=>:conversions, :min_occurs=>0}, {:type=>"double", :max_occurs=>1, :name=>:conversion_rate, :min_occurs=>0}, {:type=>"Money", :max_occurs=>1, :name=>:cost_per_conversion, :min_occurs=>0}, {:type=>"long", :max_occurs=>1, :name=>:conversions_many_per_click, :min_occurs=>0}, {:type=>"double", :max_occurs=>1, :name=>:conversion_rate_many_per_click, :min_occurs=>0}, {:type=>"Money", :max_occurs=>1, :name=>:cost_per_conversion_many_per_click, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:stats_type, :min_occurs=>0}]}, :Paging=>{:fields=>[{:type=>"int", :max_occurs=>1, :name=>:start_index, :min_occurs=>0}, {:type=>"int", :max_occurs=>1, :name=>:number_results, :min_occurs=>0}]}, :MetroTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:metro_code, :min_occurs=>0}], :base=>"GeoTarget"}, :Media_Size_DimensionsMapEntry=>{:fields=>[{:type=>"Media.Size", :max_occurs=>1, :name=>:key, :min_occurs=>0}, {:type=>"Dimensions", :max_occurs=>1, :name=>:value, :min_occurs=>0}]}, :DateRange=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:min, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:max, :min_occurs=>0}]}, :Ad=>{:fields=>[{:type=>"long", :max_occurs=>1, :name=>:id, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:url, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:display_url, :min_occurs=>0}, {:type=>"Ad.ApprovalStatus", :max_occurs=>1, :name=>:approval_status, :min_occurs=>0}, {:type=>"string", :max_occurs=>:unbounded, :name=>:disapproval_reasons, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:ad_type, :min_occurs=>0}]}, :ComparableValue=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:comparable_value_type, :min_occurs=>0}], :abstract=>true}, :ProvinceTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:province_code, :min_occurs=>0}], :base=>"GeoTarget"}, :EntityCountLimitExceeded=>{:fields=>[{:type=>"EntityCountLimitExceeded.Reason", :max_occurs=>1, :name=>:reason, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:enclosing_id, :min_occurs=>0}, {:type=>"int", :max_occurs=>1, :name=>:limit, :min_occurs=>0}], :base=>"ApiError"}, :CountryTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:country_code, :min_occurs=>0}], :base=>"GeoTarget"}, :AdStats=>{:fields=>[{:type=>"double", :max_occurs=>1, :name=>:percent_served, :min_occurs=>0}], :base=>"Stats"}, :LocalBusinessAd=>{:fields=>[{:type=>"string", :max_occurs=>1, :name=>:full_business_name, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:phone_number, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:street_address, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:city, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:region, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:region_code, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:postal_code, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:country_code, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:business_name, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:description1, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:description2, :min_occurs=>0}, {:type=>"ProximityTarget", :max_occurs=>1, :name=>:target, :min_occurs=>0}, {:type=>"Image", :max_occurs=>1, :name=>:business_image, :min_occurs=>0}, {:type=>"Image", :max_occurs=>1, :name=>:icon, :min_occurs=>0}], :base=>"Ad"}, :MobileImageAd=>{:fields=>[{:type=>"MarkupLanguageType", :max_occurs=>:unbounded, :name=>:markup_languages, :min_occurs=>0}, {:type=>"string", :max_occurs=>:unbounded, :name=>:mobile_carriers, :min_occurs=>0}, {:type=>"Image", :max_occurs=>1, :name=>:image, :min_occurs=>0}], :base=>"Ad"}, :Media_Size_StringMapEntry=>{:fields=>[{:type=>"Media.Size", :max_occurs=>1, :name=>:key, :min_occurs=>0}, {:type=>"string", :max_occurs=>1, :name=>:value, :min_occurs=>0}]}, :DoubleValue=>{:fields=>[{:type=>"double", :max_occurs=>1, :name=>:number, :min_occurs=>0}], :base=>"NumberValue"}}
|
|
12
|
+
ADGROUPADSERVICE_METHODS = {:get=>{:input=>[{:type=>"AdGroupAdSelector", :max_occurs=>1, :min_occurs=>0, :name=>:selector}], :output=>{:fields=>[{:type=>"AdGroupAdPage", :max_occurs=>1, :min_occurs=>0, :name=>:rval}], :name=>"get_response"}}, :mutate=>{:input=>[{:type=>"AdGroupAdOperation", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:operations}], :output=>{:fields=>[{:type=>"AdGroupAdReturnValue", :max_occurs=>1, :min_occurs=>0, :name=>:rval}], :name=>"mutate_response"}}}
|
|
13
|
+
ADGROUPADSERVICE_TYPES = {:LocalBusinessAd=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:full_business_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:phone_number}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:street_address}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:city}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:region}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:region_code}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:postal_code}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:country_code}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:business_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:description1}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:description2}, {:type=>"ProximityTarget", :max_occurs=>1, :min_occurs=>0, :name=>:target}, {:type=>"Image", :max_occurs=>1, :min_occurs=>0, :name=>:business_image}, {:type=>"Image", :max_occurs=>1, :min_occurs=>0, :name=>:icon}], :base=>"Ad"}, :ExemptionRequest=>{:fields=>[{:type=>"PolicyViolationKey", :max_occurs=>1, :min_occurs=>0, :name=>:key}]}, :NetworkTarget=>{:fields=>[{:type=>"NetworkCoverageType", :max_occurs=>1, :min_occurs=>0, :name=>:network_coverage_type}], :base=>"Target"}, :EntityCountLimitExceeded=>{:fields=>[{:type=>"EntityCountLimitExceeded.Reason", :max_occurs=>1, :min_occurs=>0, :name=>:reason}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:enclosing_id}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:limit}], :base=>"ApiError"}, :DateRange=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:min}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:max}]}, :AgeTarget=>{:fields=>[{:type=>"AgeTarget.Age", :max_occurs=>1, :min_occurs=>0, :name=>:age}], :base=>"DemographicTarget"}, :AdExtensionOverrideStats=>{:fields=>[], :base=>"Stats"}, :AdGroupAdOperation=>{:fields=>[{:type=>"AdGroupAd", :max_occurs=>1, :min_occurs=>0, :name=>:operand}, {:type=>"ExemptionRequest", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:exemption_requests}], :base=>"Operation"}, :PolicyViolationKey=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:policy_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:violating_text}]}, :LanguageTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:language_code}], :base=>"Target"}, :Dimensions=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:width}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:height}]}, :TemplateElement=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:unique_name}, {:type=>"TemplateElementField", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:fields}]}, :Stats=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:start_date}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:end_date}, {:type=>"Stats.Network", :max_occurs=>1, :min_occurs=>0, :name=>:network}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:clicks}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:impressions}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:cost}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:average_position}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:average_cpc}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:average_cpm}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:ctr}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:conversions}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:conversion_rate}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:cost_per_conversion}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:conversions_many_per_click}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:conversion_rate_many_per_click}, {:type=>"Money", :max_occurs=>1, :min_occurs=>0, :name=>:cost_per_conversion_many_per_click}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:stats_type}]}, :TempAdUnionId=>{:fields=>[], :base=>"AdUnionId"}, :PlatformTarget=>{:fields=>[{:type=>"PlatformType", :max_occurs=>1, :min_occurs=>0, :name=>:platform_type}], :base=>"Target"}, :DoubleValue=>{:fields=>[{:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:number}], :base=>"NumberValue"}, :CityTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:city_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:province_code}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:country_code}], :base=>"GeoTarget"}, :AdGroupAdCountLimitExceeded=>{:fields=>[], :base=>"EntityCountLimitExceeded"}, :ListReturnValue=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:list_return_value_type}], :abstract=>true}, :AdGroupAdPage=>{:fields=>[{:type=>"AdGroupAd", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:entries}], :base=>"Page"}, :Media=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:media_id}, {:type=>"Media.MediaType", :max_occurs=>1, :min_occurs=>0, :name=>:media_type_db}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:reference_id}, {:type=>"Media_Size_DimensionsMapEntry", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:dimensions}, {:type=>"Media_Size_StringMapEntry", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:urls}, {:type=>"Media.MimeType", :max_occurs=>1, :min_occurs=>0, :name=>:mime_type}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:source_url}, {:type=>"Media.MediaSubType", :max_occurs=>1, :min_occurs=>0, :name=>:media_sub_type}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:name}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:file_size}, {:type=>"Media_MediaExtendedCapabilityType_Media_MediaExtendedCapabilityStateMapEntry", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:extended_capabilities}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:creation_time}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:media_type}]}, :NumberValue=>{:fields=>[], :abstract=>true, :base=>"ComparableValue"}, :MetroTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:metro_code}], :base=>"GeoTarget"}, :Image=>{:fields=>[{:type=>"base64Binary", :max_occurs=>1, :min_occurs=>0, :name=>:data}], :base=>"Media"}, :AdGroupAdSelector=>{:fields=>[{:type=>"long", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:campaign_ids}, {:type=>"long", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:ad_group_ids}, {:type=>"long", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:ad_ids}, {:type=>"AdStatsSelector", :max_occurs=>1, :min_occurs=>0, :name=>:stats_selector}, {:type=>"Paging", :max_occurs=>1, :min_occurs=>0, :name=>:paging}]}, :TextAd=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:headline}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:description1}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:description2}], :base=>"Ad"}, :SoapHeader=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:application_token}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:auth_token}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:client_customer_id}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:client_email}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:developer_token}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:user_agent}, {:type=>"boolean", :max_occurs=>1, :min_occurs=>0, :name=>:validate_only}]}, :PolygonTarget=>{:fields=>[{:type=>"GeoPoint", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:vertices}], :base=>"GeoTarget"}, :EntityNotFound=>{:fields=>[{:type=>"EntityNotFound.Reason", :max_occurs=>1, :min_occurs=>0, :name=>:reason}], :base=>"ApiError"}, :CountryTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:country_code}], :base=>"GeoTarget"}, :AdStats=>{:fields=>[{:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:percent_served}], :base=>"Stats"}, :Operation=>{:fields=>[{:type=>"Operator", :max_occurs=>1, :min_occurs=>0, :name=>:operator}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:operation_type}], :abstract=>true}, :AdGroupAdReturnValue=>{:fields=>[{:type=>"AdGroupAd", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:value}], :base=>"ListReturnValue"}, :MobileImageAd=>{:fields=>[{:type=>"MarkupLanguageType", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:markup_languages}, {:type=>"string", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:mobile_carriers}, {:type=>"Image", :max_occurs=>1, :min_occurs=>0, :name=>:image}], :base=>"Ad"}, :"PolicyViolationError.Part"=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:index}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:length}]}, :OperationAccessDenied=>{:fields=>[{:type=>"OperationAccessDenied.Reason", :max_occurs=>1, :min_occurs=>0, :name=>:reason}], :base=>"ApiError"}, :Media_Size_DimensionsMapEntry=>{:fields=>[{:type=>"Media.Size", :max_occurs=>1, :min_occurs=>0, :name=>:key}, {:type=>"Dimensions", :max_occurs=>1, :min_occurs=>0, :name=>:value}]}, :Media_MediaExtendedCapabilityType_Media_MediaExtendedCapabilityStateMapEntry=>{:fields=>[{:type=>"Media.MediaExtendedCapabilityType", :max_occurs=>1, :min_occurs=>0, :name=>:key}, {:type=>"Media.MediaExtendedCapabilityState", :max_occurs=>1, :min_occurs=>0, :name=>:value}]}, :Address=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:street_address}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:street_address2}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:city_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:province_code}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:province_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:postal_code}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:country_code}]}, :TemplateAd=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:template_id}, {:type=>"AdUnionId", :max_occurs=>1, :min_occurs=>0, :name=>:ad_union_id}, {:type=>"TemplateElement", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:template_elements}, {:type=>"Dimensions", :max_occurs=>1, :min_occurs=>0, :name=>:dimensions}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:name}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:duration}], :base=>"Ad"}, :DemographicTarget=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:bid_modifier}], :abstract=>true, :base=>"Target"}, :SoapResponseHeader=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:request_id}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:operations}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:response_time}, {:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:units}]}, :ProvinceTarget=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:province_code}], :base=>"GeoTarget"}, :GeoPoint=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:latitude_in_micro_degrees}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:longitude_in_micro_degrees}]}, :AdStatsSelector=>{:fields=>[], :base=>"StatsSelector"}, :Page=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:total_num_entries}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:page_type}], :abstract=>true}, :TemplateElementField=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:name}, {:type=>"TemplateElementField.Type", :max_occurs=>1, :min_occurs=>0, :name=>:type}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:field_text}, {:type=>"Media", :max_occurs=>1, :min_occurs=>0, :name=>:field_media}]}, :Paging=>{:fields=>[{:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:start_index}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:number_results}]}, :Media_Size_StringMapEntry=>{:fields=>[{:type=>"Media.Size", :max_occurs=>1, :min_occurs=>0, :name=>:key}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:value}]}, :Ad=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:id}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:url}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:display_url}, {:type=>"Ad.ApprovalStatus", :max_occurs=>1, :min_occurs=>0, :name=>:approval_status}, {:type=>"string", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:disapproval_reasons}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:ad_type}]}, :Video=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:duration_millis}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:streaming_url}, {:type=>"boolean", :max_occurs=>1, :min_occurs=>0, :name=>:ready_to_play_on_the_web}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:industry_standard_commercial_identifier}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:advertising_id}], :base=>"Media"}, :StatsSelector=>{:fields=>[{:type=>"DateRange", :max_occurs=>1, :min_occurs=>0, :name=>:date_range}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:stats_selector_type}]}, :ProximityTarget=>{:fields=>[{:type=>"GeoPoint", :max_occurs=>1, :min_occurs=>0, :name=>:geo_point}, {:type=>"ProximityTarget.DistanceUnits", :max_occurs=>1, :min_occurs=>0, :name=>:radius_distance_units}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:radius_in_units}, {:type=>"Address", :max_occurs=>1, :min_occurs=>0, :name=>:address}, {:type=>"boolean", :max_occurs=>1, :min_occurs=>0, :name=>:allow_service_of_address}], :base=>"GeoTarget"}, :GenderTarget=>{:fields=>[{:type=>"GenderTarget.Gender", :max_occurs=>1, :min_occurs=>0, :name=>:gender}], :base=>"DemographicTarget"}, :Audio=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:duration_millis}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:streaming_url}, {:type=>"boolean", :max_occurs=>1, :min_occurs=>0, :name=>:ready_to_play_on_the_web}], :base=>"Media"}, :ImageAd=>{:fields=>[{:type=>"Image", :max_occurs=>1, :min_occurs=>0, :name=>:image}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:name}], :base=>"Ad"}, :ComparableValue=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:comparable_value_type}], :abstract=>true}, :MobileAd=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:headline}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:description}, {:type=>"MarkupLanguageType", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:markup_languages}, {:type=>"string", :max_occurs=>:unbounded, :min_occurs=>0, :name=>:mobile_carriers}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:business_name}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:country_code}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:phone_number}], :base=>"Ad"}, :AdScheduleTarget=>{:fields=>[{:type=>"DayOfWeek", :max_occurs=>1, :min_occurs=>0, :name=>:day_of_week}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:start_hour}, {:type=>"MinuteOfHour", :max_occurs=>1, :min_occurs=>0, :name=>:start_minute}, {:type=>"int", :max_occurs=>1, :min_occurs=>0, :name=>:end_hour}, {:type=>"MinuteOfHour", :max_occurs=>1, :min_occurs=>0, :name=>:end_minute}, {:type=>"double", :max_occurs=>1, :min_occurs=>0, :name=>:bid_multiplier}], :base=>"Target"}, :AdGroupAd=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:ad_group_id}, {:type=>"Ad", :max_occurs=>1, :min_occurs=>0, :name=>:ad}, {:type=>"AdGroupAd.Status", :max_occurs=>1, :min_occurs=>0, :name=>:status}, {:type=>"AdStats", :max_occurs=>1, :min_occurs=>0, :name=>:stats}]}, :Target=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:target_type}], :abstract=>true}, :Money=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:micro_amount}], :base=>"ComparableValue"}, :GeoTarget=>{:fields=>[{:type=>"boolean", :max_occurs=>1, :min_occurs=>0, :name=>:excluded}], :abstract=>true, :base=>"Target"}, :AdUnionId=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:id}, {:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:ad_union_id_type}]}, :LongValue=>{:fields=>[{:type=>"long", :max_occurs=>1, :min_occurs=>0, :name=>:number}], :base=>"NumberValue"}, :DeprecatedAd=>{:fields=>[{:type=>"string", :max_occurs=>1, :min_occurs=>0, :name=>:name}, {:type=>"DeprecatedAd.Type", :max_occurs=>1, :min_occurs=>0, :name=>:type}], :base=>"Ad"}}
|
|
12
14
|
ADGROUPADSERVICE_NAMESPACES = []
|
|
13
15
|
|
|
14
16
|
def self.get_method_signature(method_name)
|