hyundai-kia-connect-api 3.32.0__py2.py3-none-any.whl → 3.32.2__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.

Potentially problematic release.


This version of hyundai-kia-connect-api might be problematic. Click here for more details.

@@ -130,7 +130,7 @@ class KiaUvoApiCA(ApiImpl):
130
130
 
131
131
  def login(self, username: str, password: str) -> Token:
132
132
  # Sign In with Email and Password and Get Authorization Code
133
- url = self.API_URL + "lgn"
133
+ url = self.API_URL + "v2/login"
134
134
  data = {"loginId": username, "password": password}
135
135
  headers = self.API_HEADERS
136
136
  response = self.sessions.post(url, json=data, headers=headers)
@@ -917,17 +917,11 @@ class KiaUvoApiEU(ApiImplType1):
917
917
  url = self.SPA_API_URL_V2 + "vehicles/" + vehicle.id + "/ccs2/control/door"
918
918
 
919
919
  payload = {"command": action.value}
920
- headers = self._get_control_headers(
921
- token, vehicle
922
- )
920
+ headers = self._get_control_headers(token, vehicle)
923
921
 
924
922
  _LOGGER.debug(f"{DOMAIN} - Lock Action Request: {payload}")
925
-
926
- response = requests.post(
927
- url,
928
- json=payload,
929
- headers=headers
930
- ).json()
923
+
924
+ response = requests.post(url, json=payload, headers=headers).json()
931
925
  _LOGGER.debug(f"{DOMAIN} - Lock Action Response: {response}")
932
926
  _check_response_for_errors(response)
933
927
  token.device_id = self._get_device_id(self._get_stamp())
@@ -1029,19 +1023,15 @@ class KiaUvoApiEU(ApiImplType1):
1029
1023
  )
1030
1024
 
1031
1025
  else:
1032
- url = self.SPA_API_URL_V2 + "vehicles/" + vehicle.id + "/ccs2/control/charge"
1026
+ url = (
1027
+ self.SPA_API_URL_V2 + "vehicles/" + vehicle.id + "/ccs2/control/charge"
1028
+ )
1033
1029
 
1034
1030
  payload = {"command": "start"}
1035
- headers = self._get_control_headers(
1036
- token, vehicle
1037
- )
1031
+ headers = self._get_control_headers(token, vehicle)
1038
1032
 
1039
1033
  _LOGGER.debug(f"{DOMAIN} - Start Charge Action Request: {payload}")
1040
- response = requests.post(
1041
- url,
1042
- json=payload,
1043
- headers=headers
1044
- ).json()
1034
+ response = requests.post(url, json=payload, headers=headers).json()
1045
1035
  _LOGGER.debug(f"{DOMAIN} - Start Charge Action Response: {response}")
1046
1036
  _check_response_for_errors(response)
1047
1037
  token.device_id = self._get_device_id(self._get_stamp())
@@ -1057,19 +1047,15 @@ class KiaUvoApiEU(ApiImplType1):
1057
1047
  )
1058
1048
 
1059
1049
  else:
1060
- url = self.SPA_API_URL_V2 + "vehicles/" + vehicle.id + "/ccs2/control/charge"
1050
+ url = (
1051
+ self.SPA_API_URL_V2 + "vehicles/" + vehicle.id + "/ccs2/control/charge"
1052
+ )
1061
1053
 
1062
1054
  payload = {"command": "stop"}
1063
- headers = self._get_control_headers(
1064
- token, vehicle
1065
- )
1055
+ headers = self._get_control_headers(token, vehicle)
1066
1056
 
1067
1057
  _LOGGER.debug(f"{DOMAIN} - Stop Charge Action Request: {payload}")
1068
- response = requests.post(
1069
- url,
1070
- json=payload,
1071
- headers=headers
1072
- ).json()
1058
+ response = requests.post(url, json=payload, headers=headers).json()
1073
1059
  _LOGGER.debug(f"{DOMAIN} - Stop Charge Action Response: {response}")
1074
1060
  _check_response_for_errors(response)
1075
1061
  token.device_id = self._get_device_id(self._get_stamp())
@@ -1798,4 +1784,5 @@ class KiaUvoApiEU(ApiImplType1):
1798
1784
 
1799
1785
  # if iterate the whole notifications list and
1800
1786
  # can't find the action, raise an exception
1801
- raise APIError(f"No action found with ID {action_id}")
1787
+ # Old code: raise APIError(f"No action found with ID {action_id}")
1788
+ return OrderStatus.UNKNOWN
@@ -92,6 +92,8 @@ class OrderStatus(Enum):
92
92
  # no response received from vehicle.
93
93
  # no way to know if the order was executed, but most likely not
94
94
  TIMEOUT = "TIMEOUT"
95
+ # Used when we don't know the status of the order
96
+ UNKNOWN = "UNKNOWN"
95
97
 
96
98
 
97
99
  class WINDOW_STATE(IntEnum):
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: hyundai_kia_connect_api
3
- Version: 3.32.0
3
+ Version: 3.32.2
4
4
  Summary: Python Boilerplate contains all the boilerplate you need to create a Python package.
5
5
  Home-page: https://github.com/Hyundai-Kia-Connect/hyundai_kia_connect_api
6
6
  Author: Fuat Akgun
@@ -2,22 +2,22 @@ hyundai_kia_connect_api/ApiImpl.py,sha256=eCEQEz6L-7EN2eKnrYiHrYC0pPV-ngGFcayF0t
2
2
  hyundai_kia_connect_api/ApiImplType1.py,sha256=PnKwpbCoYGOXBWzBLIlDSrC6daIYeW9qlfW7TM4HCU0,12184
3
3
  hyundai_kia_connect_api/HyundaiBlueLinkApiUSA.py,sha256=Tx-L4ZWiPhq-uHcjWSUzjLEsfunV6nzyzqQpjPTYuIo,36831
4
4
  hyundai_kia_connect_api/KiaUvoApiAU.py,sha256=tslh0gzvPBwYJmcWlf9B0l7PyYZdy2e7GqpRkl8_Svk,48471
5
- hyundai_kia_connect_api/KiaUvoApiCA.py,sha256=QXs7Gk3uvv1719B8E-Gqe1H0hBh_jQflBJtPZZxvz2g,31460
5
+ hyundai_kia_connect_api/KiaUvoApiCA.py,sha256=Jvi-gakbtMTN8y2rsUPjuxFfxRp40LJS1HIudEmKaNs,31465
6
6
  hyundai_kia_connect_api/KiaUvoApiCN.py,sha256=cwIPZ0dU6HolKdooUQeQKlLAic6YU8dQmNs0VQDBgpQ,47035
7
- hyundai_kia_connect_api/KiaUvoApiEU.py,sha256=FiRPb_anGRDiNP41U0pFWLZ9uoLDCMAzmKWqEO_zXZU,71414
7
+ hyundai_kia_connect_api/KiaUvoApiEU.py,sha256=TxgO2dfLjKSKfSkRMoTL_fbmzRFRPb8oJ9IDztD50Ug,71300
8
8
  hyundai_kia_connect_api/KiaUvoApiUSA.py,sha256=G2sGtv88sBZuAz8qKYq_3_JNXIkxEjOBAzwM6R8GUi0,30548
9
9
  hyundai_kia_connect_api/Token.py,sha256=ZsPvXh1ID7FUTGHAqhZUZyrKT7xVbOtIn6FRJn4Ygf0,370
10
10
  hyundai_kia_connect_api/Vehicle.py,sha256=raCMzJsLuJnVHlFJ16VKdKat55L0uivbbcZRDCGWTxI,18793
11
11
  hyundai_kia_connect_api/VehicleManager.py,sha256=I0HDOsbXDen-26vyD7YR-RUgdaofOZrv_H_PPPuWjHg,11087
12
12
  hyundai_kia_connect_api/__init__.py,sha256=IkyVeIMbcFJZgLaiiNnUVA1Ferxvrm1bXHKVg01cxvc,319
13
13
  hyundai_kia_connect_api/bluelink.py,sha256=sBU7hlElie21GU4Ma-i4a5vdztGc2jtmlVBbbgUqmTE,19720
14
- hyundai_kia_connect_api/const.py,sha256=HE0_1_be4ERB73vsekWxv6TDWd8cvAgY1oPZojUrcwM,2096
14
+ hyundai_kia_connect_api/const.py,sha256=scBlhrMims0W6_pESVVdQz2uUxczg2cf2qDQ7avbhVo,2174
15
15
  hyundai_kia_connect_api/exceptions.py,sha256=m7gyDnvA5OVAK4EXSP_ZwE0s0uV8HsGUV0tiYwqofK0,1343
16
16
  hyundai_kia_connect_api/utils.py,sha256=J0aXUX-nKIoS3XbelatNh-DZlHRU2_DYz_Mg_ZUKQJU,1957
17
- hyundai_kia_connect_api-3.32.0.dist-info/AUTHORS.rst,sha256=T77OE1hrQF6YyDE6NbdMKyL66inHt7dnjHAzblwuk2A,155
18
- hyundai_kia_connect_api-3.32.0.dist-info/LICENSE,sha256=49hmc755oyMwKdZ-2epiorjStRB0PfcZR1w5_NXZPgs,1068
19
- hyundai_kia_connect_api-3.32.0.dist-info/METADATA,sha256=f624MFz_orTUhgUm4jS7JLn-lL1Udvylkb68LszHt3A,6872
20
- hyundai_kia_connect_api-3.32.0.dist-info/WHEEL,sha256=9Hm2OB-j1QcCUq9Jguht7ayGIIZBRTdOXD1qg9cCgPM,109
21
- hyundai_kia_connect_api-3.32.0.dist-info/entry_points.txt,sha256=XfrroRdyC_9q9VXjEZe5SdRPhkQyCCE4S7ZK6XSKelA,67
22
- hyundai_kia_connect_api-3.32.0.dist-info/top_level.txt,sha256=otZ7J_fN-s3EW4jD-kAearIo2OIzhQLR8DNEHIaFfds,24
23
- hyundai_kia_connect_api-3.32.0.dist-info/RECORD,,
17
+ hyundai_kia_connect_api-3.32.2.dist-info/AUTHORS.rst,sha256=T77OE1hrQF6YyDE6NbdMKyL66inHt7dnjHAzblwuk2A,155
18
+ hyundai_kia_connect_api-3.32.2.dist-info/LICENSE,sha256=49hmc755oyMwKdZ-2epiorjStRB0PfcZR1w5_NXZPgs,1068
19
+ hyundai_kia_connect_api-3.32.2.dist-info/METADATA,sha256=qI8TIsoBTLs8h1vXj233g8Wz3vBRU_vzq35I5nUIXSA,6872
20
+ hyundai_kia_connect_api-3.32.2.dist-info/WHEEL,sha256=9Hm2OB-j1QcCUq9Jguht7ayGIIZBRTdOXD1qg9cCgPM,109
21
+ hyundai_kia_connect_api-3.32.2.dist-info/entry_points.txt,sha256=XfrroRdyC_9q9VXjEZe5SdRPhkQyCCE4S7ZK6XSKelA,67
22
+ hyundai_kia_connect_api-3.32.2.dist-info/top_level.txt,sha256=otZ7J_fN-s3EW4jD-kAearIo2OIzhQLR8DNEHIaFfds,24
23
+ hyundai_kia_connect_api-3.32.2.dist-info/RECORD,,