For the eWeLink API entry, respect the account's region when choosing the API host.
CoolKit's official reference documents error 10004 for an account belonging to another region and provides region information for selecting the appropriate server.
Handle that response explicitly instead of retrying the same login against the same host. Keep the documented regional mapping separate from arbitrary redirects, and test the flow without issuing commands to real devices.