dsdanielpark / Gemini-API

The unofficial python package that returns response of Google Gemini through cookie values.
https://pypi.org/project/python-gemini-api/
MIT License
148 stars 11 forks source link

Error after using rcid for previous chat session #27

Closed mdatiqmazumder closed 3 months ago

mdatiqmazumder commented 3 months ago

Failed to generate content due to an error: All parsing strategies failed. Try to use Gemini.send_request(prompt) to get original payload.. Return reponse without parse. If the issue persists, submit it at https://github.com/dsdanielpark/Gemini-API/issues )]}'

dsdanielpark commented 3 months ago

I updated readme session.

RCID may not persist. If parsing fails, reset GeminiClient.rcid to None.

GeminiClient.rcid = None

And if you check your raw response payload. Try to use send_request method.

prompt = "Hi, Gemini?"
payload, status_code = GeminiClient.send_request(prompt)
print(payload)