<s> from libsaas import http , parsers <EOL> from libsaas . services import base <EOL> from . import ads <EOL> class Advertiser ( base . HierarchicalResource ) : <EOL> path = '<STR_LIT>' <EOL> @ base . resource ( ads . TextAd ) <EOL> def textad ( self , hash ) : <EOL> """<STR_LIT>""" <EOL> return ads . TextAd ( self , hash ) <EOL> @ base . resource ( ads . DisplayAd ) <EOL> def displayad ( self , hash ) : <EOL> """<STR_LIT>""" <EOL> return ads . DisplayAd ( self , hash ) <EOL> @ base . apimethod <EOL> def summary ( self ) : <EOL> """<STR_LIT>""" <EOL> request = http . Request ( '<STR_LIT:GET>' , self . get_url ( ) ) <EOL> return request , parsers . parse_json <EOL> @ base . apimethod <EOL> def textads ( self , offset = None , page_size = None , min_avg_position = None , <EOL> max_avg_position = None , min_times_seen = None , <EOL> max_times_seen = None , first_seen_before = None , <EOL> first_seen_after = None , last_seen_before = None , <EOL> last_seen_after = None , sort_field = None , sort_order = None ) : <EOL> """<STR_LIT>""" <EOL> params = base . get_params ( None , locals ( ) ) <EOL> url = self . get_url ( ) + '<STR_LIT>' <EOL> request = http . Request ( '<STR_LIT:GET>' , url , params ) <EOL> return request , parsers . parse_json <EOL> @ base . apimethod <EOL> def displayads ( self , offset = None , page_size = None , min_times_seen = None , <EOL> max_times_seen = None , first_seen_before = None , <EOL> first_seen_after = None , last_seen_before = None , <EOL> last_seen_after = None , sort_field = None , sort_order = None ) : <EOL> """<STR_LIT>""" <EOL> params = base . get_params ( None , locals ( ) ) <EOL> url = self . get_url ( ) + '<STR_LIT>' <EOL> request = http . Request ( '<STR_LIT:GET>' , url , params ) <EOL> return request , parsers . parse_json <EOL> @ base . apimethod <EOL> def publishers ( self , offset = None , page_size = None , min_times_seen = None , <EOL> max_times_seen = None , min_monthly_uniques = None , <EOL> max_monthly_uniques = None , last_seen_before = None , <EOL> last_seen_after = None , sort_field = None , sort_order = None ) : <EOL> """<STR_LIT>""" <EOL> params = base . get_params ( None , locals ( ) ) <EOL> url = self . get_url ( ) + '<STR_LIT>' <EOL> request = http . Request ( '<STR_LIT:GET>' , url , params ) <EOL> return request , parsers . parse_json <EOL> @ base . apimethod <EOL> def keywords ( self , offset = None , page_size = None , min_times_seen = None , <EOL> max_times_seen = None , first_seen_before = None , <EOL> first_seen_after = None , last_seen_before = None , <EOL> last_seen_after = None , sort_field = None , sort_order = None ) : <EOL> """<STR_LIT>""" <EOL> params = base . get_params ( None , locals ( ) ) <EOL> url = self . get_url ( ) + '<STR_LIT>' <EOL> request = http . Request ( '<STR_LIT:GET>' , url , params ) <EOL> return request , parsers . parse_json </s>
