python-terminusgps 36.9.2__py3-none-any.whl → 36.10.0__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.
- {python_terminusgps-36.9.2.dist-info → python_terminusgps-36.10.0.dist-info}/METADATA +1 -1
- {python_terminusgps-36.9.2.dist-info → python_terminusgps-36.10.0.dist-info}/RECORD +5 -5
- terminusgps/wialon/utils.py +24 -1
- {python_terminusgps-36.9.2.dist-info → python_terminusgps-36.10.0.dist-info}/WHEEL +0 -0
- {python_terminusgps-36.9.2.dist-info → python_terminusgps-36.10.0.dist-info}/licenses/COPYING +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: python-terminusgps
|
|
3
|
-
Version: 36.
|
|
3
|
+
Version: 36.10.0
|
|
4
4
|
Summary: Provides abstractions/utilities for working with Wialon API, Authorize.NET API, AWS API, and more.
|
|
5
5
|
Project-URL: Documentation, https://docs.terminusgps.com
|
|
6
6
|
Project-URL: Repository, https://github.com/terminusgps/python-terminusgps
|
|
@@ -38,7 +38,7 @@ terminusgps/wialon/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuF
|
|
|
38
38
|
terminusgps/wialon/constants.py,sha256=05pLc_0S-x0tT87cQcxOmr8plesjOQxoXfUdjIHwI90,7732
|
|
39
39
|
terminusgps/wialon/flags.py,sha256=M50EdhxQ8IMnJnU0mrHK7-h8Asc6tvNiTOOfd1dBW6A,12815
|
|
40
40
|
terminusgps/wialon/session.py,sha256=eWRAWEikYdGr-0xa6yGHfTAxlCx9-1vsZDNwNZUJjZM,13771
|
|
41
|
-
terminusgps/wialon/utils.py,sha256=
|
|
41
|
+
terminusgps/wialon/utils.py,sha256=ntHLAVJSJBdIgJK704xxFNFRopaFz-No9YZZOMmvWO8,11627
|
|
42
42
|
terminusgps/wialon/validators.py,sha256=j5vrtcfClAzRdRkWTvRRAmrne1t0R6cKkmYdE7fAkSs,4247
|
|
43
43
|
terminusgps/wialon/items/__init__.py,sha256=3BVthghekMvhMQSzQgBMlD_phxmKSmp3Zvmo-z0O8Bs,211
|
|
44
44
|
terminusgps/wialon/items/base.py,sha256=vS8xIo5WLiwzpB81i7aHFnwOHzCf4lQG6azjq79HDM4,11775
|
|
@@ -52,7 +52,7 @@ terminusgps/wialon/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZ
|
|
|
52
52
|
terminusgps/wialon/tests/test_items.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
53
53
|
terminusgps/wialon/tests/test_session.py,sha256=9mBlYchMo9NeqRIZsmxYzrM1zBHorqu4ooxqSNppLpI,1336
|
|
54
54
|
terminusgps/wialon/tests/test_utils.py,sha256=SK4PxJQGECFnzx_EQeRAQfsQ5_3FLaVcis2W9u_ibuI,1730
|
|
55
|
-
python_terminusgps-36.
|
|
56
|
-
python_terminusgps-36.
|
|
57
|
-
python_terminusgps-36.
|
|
58
|
-
python_terminusgps-36.
|
|
55
|
+
python_terminusgps-36.10.0.dist-info/METADATA,sha256=_LHMHHTATMGd7I9D7RCUxM01_nFQt_59JnjXK-tIZEk,1265
|
|
56
|
+
python_terminusgps-36.10.0.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
57
|
+
python_terminusgps-36.10.0.dist-info/licenses/COPYING,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
|
58
|
+
python_terminusgps-36.10.0.dist-info/RECORD,,
|
terminusgps/wialon/utils.py
CHANGED
|
@@ -7,6 +7,29 @@ from .items import WialonResource, WialonUnit
|
|
|
7
7
|
from .session import WialonSession
|
|
8
8
|
|
|
9
9
|
|
|
10
|
+
def get_hw_types(session: WialonSession) -> list[dict[str, str | int]]:
|
|
11
|
+
"""
|
|
12
|
+
Returns a list of hardware type objects for Wialon.
|
|
13
|
+
|
|
14
|
+
:param session: A valid Wialon API session.
|
|
15
|
+
:type session: :py:obj:`~terminusgps.wialon.session.WialonSession`
|
|
16
|
+
:returns: A list of hardware types.
|
|
17
|
+
:rtype: :py:obj:`list`
|
|
18
|
+
|
|
19
|
+
Hardware type format:
|
|
20
|
+
|
|
21
|
+
+----------+--------------------+
|
|
22
|
+
| key | value |
|
|
23
|
+
+==========+====================+
|
|
24
|
+
| ``id`` | Hardware type id |
|
|
25
|
+
+----------+--------------------+
|
|
26
|
+
| ``name`` | Hardware type name |
|
|
27
|
+
+----------+--------------------+
|
|
28
|
+
|
|
29
|
+
"""
|
|
30
|
+
return session.wialon_api.core_get_hw_types()
|
|
31
|
+
|
|
32
|
+
|
|
10
33
|
def get_user_by_name(name: str, session: WialonSession) -> WialonUnit | None:
|
|
11
34
|
"""
|
|
12
35
|
Returns a Wialon user by name, if it exists.
|
|
@@ -232,7 +255,7 @@ def get_unit_by_imei(imei: str, session: WialonSession) -> WialonUnit | None:
|
|
|
232
255
|
return WialonUnit(id=results["items"][0].get("id"), session=session)
|
|
233
256
|
|
|
234
257
|
|
|
235
|
-
def get_vin_info(vin_number: str, session: WialonSession) -> dict:
|
|
258
|
+
def get_vin_info(vin_number: str, session: WialonSession) -> dict[str, typing.Any]:
|
|
236
259
|
"""
|
|
237
260
|
Retrieves vehicle data from a VIN number.
|
|
238
261
|
|
|
File without changes
|
{python_terminusgps-36.9.2.dist-info → python_terminusgps-36.10.0.dist-info}/licenses/COPYING
RENAMED
|
File without changes
|