Aedial/novelai-api

Please add proxy setting to connect api

zmdyy0318 opened this issue · 3 comments

My country access interface is very poor

Hi, can you try with the proxy_impl branch ? Some helpers have been put in the generate_image.py example, and the aiohttp documentation on proxy should also help a lot: https://docs.aiohttp.org/en/stable/client_advanced.html#proxy-support.

I have tried connecting my own proxy service and he works fine

# insert proxy address here
api_inst.api.proxy = "http://127.0.0.1:7890"
# insert proxy address auth here
api_inst.api.proxy_auth = None

Pushed onto the main branch with f5a4448