Skip to content

API changed? #6

Description

@skapow

Thank you for providing the script.

I was trying to run it on a windows python installation, but couldn't manage to get useful data. I'm also new to python, so please excuse, in case I am asking stupid questions.

I'm using Python 3.13.7.

I got past the authentification, but the results of
plants = await plants_api.async_get_plants()
are quite cryptic:

{'result_msg': 'success', 'access_token': 'XXX', 'refresh_token': 'XXX', 'scope': 'all', 'result_data': {'access_token': 'XXX', 'refresh_token': 'XXX', 'auth_user': XXX, 'token_type': 'bearer', 'expires_in': XXX, 'auth_ps_list': ['XXX']}, 'result_code': '1', 'token_type': 'bearer', 'expires_in': 172451, 'req_serial_num': 'XXX'}
Unclosed client session
client_session: <aiohttp.client.ClientSession object at 0x000002415BCE1010>
Unclosed connector
connections: ['deque([(<aiohttp.client_proto.ResponseHandler object at 0x000002415C895970>, 8248.3243461)])']
connector: <aiohttp.connector.TCPConnector object at 0x000002415BCE1160>

I replaced the tokens and IDs here.

Could it be that Sungrow changed their API, or the newer Python version creates issues?

Any help is appreciated!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions