| | |
| | | print(e) |
| | | return |
| | | else: |
| | | yield f"Error: {response.status_code}" |
| | | yield f"Error: {response.status_code}" |
| | | |
| | | async def questions_talk(self, chat_id: str): |
| | | url = f"{self.base_url}/questions/talk" |
| | | params = {'chat_id': chat_id} |
| | | headers = {'Content-Type': 'text/plain'} |
| | | async with httpx.AsyncClient() as client: |
| | | response = await client.post( |
| | | url, |
| | | headers=headers, |
| | | params=params |
| | | ) |
| | | return self._check_response(response) |
| | | |
| | | async def questions_talk_word_download(self, file_id: str): |
| | | url = f"{self.base_url}/questions/download/word" |
| | | return await self.download_from_url(url, params={'excel_name': file_id}) |