예제 #1
0
 def __init__(self):
   self.transport = THttpClient.THttpClient("https://"+self.host,None, self.http_query_path)
   self.transport.setCustomHeaders({
     "X-Line-Application" : self.LA,"User-Agent" : self.UA})
   self.transport.open()
   self.protocol = TCompactProtocol.TCompactProtocol(self.transport);
   self.client = LineService.Client(self.protocol)
예제 #2
0
 def __init__(self, authToken):
   self.transport = THttpClient.THttpClient("https://"+self.host, None, self.http_query_path)
   self.transport.path = self.auth_query_path
   self.transport.setCustomHeaders({"X-Line-Application" : self.LA,"User-Agent" : self.UA,"X-Line-Access": authToken})
   self.protocol = TCompactProtocol.TCompactProtocol(self.transport);
   self.client = LineService.Client(self.protocol)
   self.rev = self.client.getLastOpRevision()
   self.transport.path = self.polling_path
   self.transport.open()
예제 #3
0
 def __init__(self, authToken):
     self.authToken = authToken
     self.transport = THttpClient.THttpClient("https://"+self.host, None, self.http_query_path)
     self.transport.path = self.http_query_path
     self.transport.setCustomHeaders({"X-Line-Application" : self.LA,"User-Agent" : self.UA,"X-Line-Access": authToken})
     self.transport.open()
     self.protocol = TCompactProtocol.TCompactProtocol(self.transport)
     self.client = LineService.Client(self.protocol)
     self.mid = self.client.getProfile().mid
     self.transport.path = self.channel_query_path
예제 #4
0
파일: Talk.py 프로젝트: lineX7/korps1
 def __init__(self):
     self.transport = THttpClient.THttpClient(
         'https://gf.line.naver.jp:80' + self.auth_query_path)
     self.transport.setCustomHeaders({
         "User-Agent": self.UA,
         "X-Line-Application": self.LA,
     })
     self.transport.open()
     self.protocol = TCompactProtocol.TCompactProtocol(self.transport)
     self.client = LineService.Client(self.protocol)