import path_setting
from in_common.base_request import BaseRequest


class conversation_request(BaseRequest):
    def __init__(self):
        self.messageread = self.api_load(path_setting.MESSAGE_READ_CONFIG)

    def message_read(self,current_city_id,release,message_ids):
        self.params["current_city_id"] = current_city_id
        self.params["release"] = release
        #self.params["uqid"] = uqid
        self.params["message_ids"] = message_ids
        return self.api_send(self.messageread["message_read"])

    def detail_messageid(self, os_version, last_msg_id, offset_msg_id):
        self.params["os_version"] = os_version
        self.params["last_msg_id"] = last_msg_id
        self.params["offset_msg_id"] = offset_msg_id
        return self.api_send(self.messageread["detail_messageid"])

    #直播间私信主播
    def detail_live(self, referrer_id):
       # self.params["referrer"] = referrer
        self.params["referrer_id"] = referrer_id
       # self.params["last_msg_id"] = last_msg_id
      #  self.params["offset_msg_id"] = offset_msg_id

        return self.api_send(self.messageread["detail_live"])


if __name__ == '__main__':
    print(conversation_request().message_read("beijing", 1,'[10622,10626,10646,10651]'))
    print("---------")
    print(conversation_request().detail_messageid(10, 0, 0))
    print(conversation_request().detail_live(737))





