python-terminusgps 1.17.1__tar.gz → 1.18.0__tar.gz

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 python-terminusgps might be problematic. Click here for more details.

Files changed (38) hide show
  1. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/PKG-INFO +1 -1
  2. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/pyproject.toml +1 -1
  3. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/constants.py +1 -38
  4. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/items/base.py +2 -7
  5. python_terminusgps-1.18.0/terminusgps/wialon/items/geofence.py +57 -0
  6. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/items/resource.py +21 -12
  7. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/items/retranslator.py +10 -14
  8. python_terminusgps-1.18.0/terminusgps/wialon/items/route.py +30 -0
  9. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/items/unit.py +14 -14
  10. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/items/unit_group.py +9 -10
  11. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/items/user.py +12 -15
  12. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/uv.lock +1 -1
  13. python_terminusgps-1.17.1/terminusgps/wialon/items/route.py +0 -21
  14. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/.gitignore +0 -0
  15. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/COPYING +0 -0
  16. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/README.md +0 -0
  17. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/__init__.py +0 -0
  18. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/authorizenet/__init__.py +0 -0
  19. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/authorizenet/auth.py +0 -0
  20. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/authorizenet/profiles/__init__.py +0 -0
  21. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/authorizenet/profiles/addresses.py +0 -0
  22. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/authorizenet/profiles/base.py +0 -0
  23. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/authorizenet/profiles/customers.py +0 -0
  24. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/authorizenet/profiles/payments.py +0 -0
  25. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/authorizenet/subscriptions.py +0 -0
  26. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/aws/__init__.py +0 -0
  27. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/aws/secrets.py +0 -0
  28. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/aws/ses.py +0 -0
  29. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/settings.py +0 -0
  30. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/twilio/__init__.py +0 -0
  31. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/twilio/caller.py +0 -0
  32. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/__init__.py +0 -0
  33. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/errors.py +0 -0
  34. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/flags.py +0 -0
  35. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/items/__init__.py +0 -0
  36. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/items/notification.py +0 -0
  37. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/session.py +0 -0
  38. {python_terminusgps-1.17.1 → python_terminusgps-1.18.0}/terminusgps/wialon/utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: python-terminusgps
3
- Version: 1.17.1
3
+ Version: 1.18.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://app.terminusgps.com/docs/apps/python-terminusgps/index.html
6
6
  Project-URL: Repository, https://github.com/terminusgps/python-terminusgps
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "python-terminusgps"
3
- version = "1.17.1"
3
+ version = "1.18.0"
4
4
  description = "Provides abstractions/utilities for working with Wialon API, Authorize.NET API, AWS API, and more."
5
5
  readme = "README.md"
6
6
  authors = [ {name = "Blake Nall", email = "blake@terminusgps.com" } ]
@@ -1,42 +1,6 @@
1
- from django.db import models
2
- from django.utils.translation import gettext_lazy as _
3
-
4
1
  from terminusgps.wialon import flags
5
2
 
6
-
7
- class WialonCommandName(models.TextChoices):
8
- SUB_BASIC = "Basic", _("Basic Subscription")
9
- SUB_STANDARD = "Standard", _("Standard Subscription")
10
- SUB_PREMIUM = "Premium", _("Premium Subscription")
11
- STARTER_DISABLED = "Starter Disable On", _("Disable Starter")
12
- STARTER_ENABLED = "Starter Disable Off", _("Enable Starter")
13
- ENABLE = "On", _("Enable")
14
- DISABLE = "Off", _("Disable")
15
-
16
-
17
- class WialonCommandType(models.TextChoices):
18
- ENGINE_BLOCK = "block_engine", _("Block Engine")
19
- ENGINE_UNBLOCK = "unblock_engine", _("Unblock Engine")
20
- CUSTOM_MSG = "custom_msg", _("Custom Message")
21
- DRIVER_MSG = "driver_msg", _("Message to Driver")
22
- DOWNLOAD_MSG = "download_msgs", _("Download messages")
23
- QUERY_POS = "query_pos", _("Query Position")
24
- QUERY_PHOTO = "query_photo", _("Query Snapshot")
25
- OUTPUT_ON = "output_on", _("Activate Output")
26
- OUTPUT_OFF = "output_off", _("Deactive Output")
27
- SEND_POS = "send_position", _("Send Coordinates")
28
- SET_REPORT_INT = "set_report_interval", _("Set Data Transfer Interval")
29
- UPLOAD_CFG = "upload_cfg", _("Upload Configuration")
30
- UPLOAD_SW = "upload_sw", _("Upload Firmware")
31
-
32
-
33
- class WialonCommandLink(models.TextChoices):
34
- AUTO = "", _("Auto")
35
- TCP = "tcp", _("TCP")
36
- UDP = "udp", _("UDP")
37
- VRT = "vrt", _("Virtual")
38
- GSM = "gsm", _("SMS")
39
-
3
+ ACCESSMASK_UNIT_FULL: int = flags.ACCESSFLAG_FULL_ACCESS
40
4
 
41
5
  ACCESSMASK_UNIT_BASIC: int = sum(
42
6
  [
@@ -74,7 +38,6 @@ ACCESSMASK_UNIT_SUPER: int = sum(
74
38
  ]
75
39
  )
76
40
 
77
- ACCESSMASK_UNIT_FULL: int = flags.ACCESSFLAG_FULL_ACCESS
78
41
 
79
42
  ACCESSMASK_UNIT_MIGRATION: int = sum(
80
43
  [
@@ -7,18 +7,13 @@ from terminusgps.wialon.session import WialonSession
7
7
 
8
8
  class WialonBase:
9
9
  def __init__(
10
- self,
11
- id: str | int | None = None,
12
- session: WialonSession | None = None,
13
- **kwargs,
10
+ self, id: str | int | None, session: WialonSession, *args, **kwargs
14
11
  ) -> None:
15
- if session is None:
16
- raise ValueError("A valid Wialon API session is required.")
17
12
  if isinstance(id, str) and not id.isdigit():
18
13
  raise ValueError(f"'id' must be a digit. Got '{id}'.")
19
14
 
20
15
  self._session = session
21
- self._id = str(id if id else self.create(**kwargs))
16
+ self._id = str(id if id else self.create(*args, **kwargs))
22
17
  self.populate()
23
18
 
24
19
  def __str__(self) -> str:
@@ -0,0 +1,57 @@
1
+ from django.db import models
2
+
3
+ from terminusgps.wialon.items.base import WialonBase
4
+
5
+
6
+ class WialonGeofence(WialonBase):
7
+ class WialonGeofenceShape(models.IntegerChoices):
8
+ LINE = 1
9
+ POLYGON = 2
10
+ CIRCLE = 3
11
+
12
+ class WialonGeofenceColor(models.IntegerChoices):
13
+ RED = int("ff0000", 16)
14
+ ORANGE = int("ff7b00", 16)
15
+ YELLOW = int("fffb00", 16)
16
+ GREEN = int("20ff00", 16)
17
+ BLUE = int("0090ff", 16)
18
+ PURPLE = int("7000ff", 16)
19
+ WHITE = int("f3f3f3", 16)
20
+ BLACK = int("030303", 16)
21
+
22
+ def create(
23
+ self,
24
+ resource_id: str | int,
25
+ name: str,
26
+ xpos: float,
27
+ ypos: float,
28
+ desc: str | None = None,
29
+ shape: int = WialonGeofenceShape.CIRCLE,
30
+ width: int = 100,
31
+ flags: int = 0x04,
32
+ color: int = WialonGeofenceColor.GREEN,
33
+ text_color: int = WialonGeofenceColor.BLACK,
34
+ text_size: int = 12,
35
+ min_zoom: int = 2,
36
+ max_zoom: int = 19,
37
+ ) -> int | None:
38
+ response = self.session.wialon_api.resource_update_zone(
39
+ **{
40
+ "itemId": resource_id,
41
+ "id": 0,
42
+ "callMode": "create",
43
+ "n": name,
44
+ "d": desc if desc else name,
45
+ "t": shape,
46
+ "w": width,
47
+ "f": flags,
48
+ "c": color,
49
+ "tc": text_color,
50
+ "ts": text_size,
51
+ "min": min_zoom,
52
+ "max": max_zoom,
53
+ "p": [{"x": xpos, "y": ypos, "r": width}],
54
+ }
55
+ )
56
+ if response:
57
+ return int(response[0])
@@ -3,22 +3,31 @@ from terminusgps.wialon.items.base import WialonBase
3
3
 
4
4
 
5
5
  class WialonResource(WialonBase):
6
- def create(self, **kwargs) -> int | None:
7
- if not kwargs.get("creator_id"):
8
- raise ValueError("'creator_id' is required for creation.")
9
- if not kwargs.get("name"):
10
- raise ValueError("'name' is required for creation.")
11
- if not kwargs.get("flags"):
12
- kwargs["flags"] = flags.DATAFLAG_UNIT_BASE
6
+ def create(self, creator_id: str | int, name: str) -> int | None:
7
+ """
8
+ Creates a new Wialon resource.
9
+
10
+ :param creator_id: A Wialon user id.
11
+ :type creator_id: :py:obj:`int` | :py:obj:`str`
12
+ :param name: A name for the resource.
13
+ :type name: :py:obj:`str`
14
+ :raises ValueError: If ``creator_id`` is not a digit.
15
+ :raises WialonError: If something goes wrong with Wialon.
16
+ :returns: The Wialon id for the new resource, if it was created.
17
+ :rtype: :py:obj:`int` | :py:obj:`None`
18
+
19
+ """
20
+ if isinstance(creator_id, str) and not creator_id.isdigit():
21
+ raise ValueError(f"'creator_id' must be a digit, got '{creator_id}'.")
13
22
 
14
23
  response = self.session.wialon_api.core_create_resource(
15
24
  **{
16
- "creatorId": kwargs["creator_id"],
17
- "name": kwargs["name"],
18
- "dataFlags": kwargs["flags"],
25
+ "creatorId": creator_id,
26
+ "name": name,
27
+ "dataFlags": flags.DATAFLAG_UNIT_BASE,
19
28
  }
20
29
  )
21
- return response.get("item", {}).get("id")
30
+ return int(response.get("item", {}).get("id")) if response.get("item") else None
22
31
 
23
32
  def delete(self) -> None:
24
33
  """
@@ -61,7 +70,7 @@ class WialonResource(WialonBase):
61
70
  response = self.session.wialon_api.core_search_item(
62
71
  **{"id": self.id, "flags": flags.DATAFLAG_RESOURCE_BILLING_PROPERTIES}
63
72
  )
64
- return response.get("item", {}).get("bact") == self.id
73
+ return int(response.get("item", {}).get("bact")) == self.id
65
74
 
66
75
  def is_migrated(self, unit: WialonBase) -> bool:
67
76
  """
@@ -3,13 +3,13 @@ from terminusgps.wialon.items.base import WialonBase
3
3
 
4
4
 
5
5
  class WialonRetranslator(WialonBase):
6
- def create(self, **kwargs) -> int | None:
6
+ def create(self, creator_id: str | int, name: str, config: dict) -> int | None:
7
7
  """
8
8
  Creates a Wialon retranslator.
9
9
 
10
- :param creator_id: A Wialon user that will create the retranslator.
11
- :type creator_id: :py:obj:`str`
12
- :param name: A name for the new retranslator.
10
+ :param creator_id: A Wialon user id.
11
+ :type creator_id: :py:obj:`str` | :py:obj:`int`
12
+ :param name: A name for the retranslator.
13
13
  :type name: :py:obj:`str`
14
14
  :param config: A Wialon retranslator configuration object.
15
15
  :type config: :py:obj:`dict`
@@ -19,22 +19,18 @@ class WialonRetranslator(WialonBase):
19
19
  :rtype: :py:obj:`None`
20
20
 
21
21
  """
22
- if not kwargs.get("creator_id"):
23
- raise ValueError("'creator_id' is required on creation.")
24
- if not kwargs.get("name"):
25
- raise ValueError("'name' is required on creation.")
26
- if not kwargs.get("config"):
27
- raise ValueError("'config' is required on creation.")
22
+ if isinstance(creator_id, str) and not creator_id.isdigit():
23
+ raise ValueError(f"'creator_id' must be a digit, got '{creator_id}'.")
28
24
 
29
25
  response = self.session.wialon_api.core_create_retranslator(
30
26
  **{
31
- "creatorId": kwargs["creator_id"],
32
- "name": kwargs["name"],
33
- "config": kwargs["config"],
27
+ "creatorId": creator_id,
28
+ "name": name,
29
+ "config": config,
34
30
  "dataFlags": flags.DATAFLAG_UNIT_BASE,
35
31
  }
36
32
  )
37
- return response.get("item", {}).get("id")
33
+ return int(response.get("item", {}).get("id")) if response.get("item") else None
38
34
 
39
35
  def update_config(self, new_config: dict) -> None:
40
36
  """
@@ -0,0 +1,30 @@
1
+ from terminusgps.wialon import flags
2
+ from terminusgps.wialon.items.base import WialonBase
3
+
4
+
5
+ class WialonRoute(WialonBase):
6
+ def create(self, creator_id: str | int, name: str) -> int | None:
7
+ """
8
+ Creates a new Wialon route.
9
+
10
+ :param creator_id: A Wialon user id.
11
+ :type creator_id: :py:obj:`str` | :py:obj:`int`
12
+ :param name: A name for the route.
13
+ :type name: :py:obj:`str`
14
+ :raises ValueError: If ``creator_id`` is not a digit.
15
+ :raises WialonError: If something goes wrong with Wialon.
16
+ :returns: The Wialon id for the new route, if it was created.
17
+ :rtype: :py:obj:`int` | :py:obj:`None`
18
+
19
+ """
20
+ if isinstance(creator_id, str) and not creator_id.isdigit():
21
+ raise ValueError(f"'creator_id' must be a digit, got '{creator_id}'.")
22
+
23
+ response = self.session.wialon_api.core_create_route(
24
+ **{
25
+ "creatorId": creator_id,
26
+ "name": name,
27
+ "dataFlags": flags.DATAFLAG_UNIT_BASE,
28
+ }
29
+ )
30
+ return int(response.get("item", {}).get("id")) if response.get("item") else None
@@ -5,36 +5,36 @@ from terminusgps.wialon.items.base import WialonBase
5
5
 
6
6
 
7
7
  class WialonUnit(WialonBase):
8
- def create(self, **kwargs) -> int | None:
8
+ def create(
9
+ self, creator_id: str | int, name: str, hw_type_id: str | int
10
+ ) -> int | None:
9
11
  """
10
12
  Creates a new Wialon unit.
11
13
 
12
14
  :param creator_id: A Wialon user id.
13
- :type creator_id: :py:obj:`int`
14
- :param name: A new name for the unit.
15
+ :type creator_id: :py:obj:`str` | :py:obj:`int`
16
+ :param name: A name for the unit.
15
17
  :type name: :py:obj:`str`
16
18
  :param hw_type_id: A Wialon hardware type ID.
17
- :type hw_type_id: :py:obj:`str`
19
+ :type hw_type_id: :py:obj:`str` | :py:obj:`int`
18
20
  :returns: The Wialon id for the new unit.
19
21
  :rtype: :py:obj:`int` | :py:obj:`None`
20
22
 
21
23
  """
22
- if not kwargs.get("creator_id"):
23
- raise ValueError("'creator_id' is required on creation.")
24
- if not kwargs.get("name"):
25
- raise ValueError("'name' is required on creation.")
26
- if not kwargs.get("hw_type_id"):
27
- raise ValueError("'hw_type_id' is required on creation.")
24
+ if isinstance(creator_id, str) and not creator_id.isdigit():
25
+ raise ValueError(f"'creator_id' must be a digit, got '{creator_id}'.")
26
+ if isinstance(hw_type_id, str) and not hw_type_id.isdigit():
27
+ raise ValueError(f"'hw_type_id' must be a digit, got '{hw_type_id}'.")
28
28
 
29
29
  response = self.session.wialon_api.core_create_unit(
30
30
  **{
31
- "creatorId": kwargs["creator_id"],
32
- "name": kwargs["name"],
33
- "hwTypeId": kwargs["hw_type_id"],
31
+ "creatorId": creator_id,
32
+ "name": name,
33
+ "hwTypeId": hw_type_id,
34
34
  "dataFlags": flags.DATAFLAG_UNIT_BASE,
35
35
  }
36
36
  )
37
- return response.get("item", {}).get("id")
37
+ return int(response.get("item", {}).get("id")) if response.get("item") else None
38
38
 
39
39
  @property
40
40
  def available_commands(self) -> dict:
@@ -4,33 +4,32 @@ from terminusgps.wialon.items.base import WialonBase
4
4
 
5
5
 
6
6
  class WialonUnitGroup(WialonBase):
7
- def create(self, **kwargs) -> int | None:
7
+ def create(self, creator_id: str | int, name: str) -> int | None:
8
8
  """
9
9
  Creates a new Wialon unit group.
10
10
 
11
11
  :param creator_id: A Wialon user id.
12
- :type creator_id: :py:obj:`int`
12
+ :type creator_id: :py:obj:`str` | :py:obj:`int`
13
13
  :param name: A name for the group.
14
14
  :type name: :py:obj:`str`
15
+ :raises ValueError: If ``creator_id`` is not a digit.
15
16
  :raises WialonError: If something goes wrong with Wialon.
16
- :returns: The Wialon id for the new group.
17
+ :returns: The Wialon id for the new group, if it was created.
17
18
  :rtype: :py:obj:`int` | :py:obj:`None`
18
19
 
19
20
  """
20
21
 
21
- if not kwargs.get("creator_id"):
22
- raise ValueError("'creator_id' is required on creation.")
23
- if not kwargs.get("name"):
24
- raise ValueError("'name' is required on creation.")
22
+ if isinstance(creator_id, str) and not creator_id.isdigit():
23
+ raise ValueError(f"'creator_id' must be a digit, got '{creator_id}'.")
25
24
 
26
25
  response = self.session.wialon_api.core_create_unit_group(
27
26
  **{
28
- "creatorId": kwargs["creator_id"],
29
- "name": kwargs["name"],
27
+ "creatorId": creator_id,
28
+ "name": name,
30
29
  "dataFlags": flags.DATAFLAG_UNIT_BASE,
31
30
  }
32
31
  )
33
- return response.get("item", {}).get("id")
32
+ return int(response.get("item", {}).get("id")) if response.get("item") else None
34
33
 
35
34
  def set_items(self, new_items: list[str]) -> None:
36
35
  """
@@ -5,37 +5,34 @@ from terminusgps.wialon.items.base import WialonBase
5
5
 
6
6
 
7
7
  class WialonUser(WialonBase):
8
- def create(self, **kwargs) -> int | None:
8
+ def create(self, creator_id: str | int, name: str, password: str) -> int | None:
9
9
  """
10
10
  Creates a new Wialon user.
11
11
 
12
12
  :param creator_id: A Wialon user id.
13
- :type creator_id: :py:obj:`int`
13
+ :type creator_id: :py:obj:`str` | :py:obj:`int`
14
14
  :param name: A name for the user.
15
15
  :type name: :py:obj:`str`
16
- :param name: A password for the user.
17
- :type name: :py:obj:`str`
16
+ :param password: A password for the user.
17
+ :type password: :py:obj:`str`
18
+ :raises ValueError: If ``creator_id`` is not a digit.
18
19
  :raises WialonError: If something goes wrong with Wialon.
19
- :returns: The Wialon id for the new user.
20
+ :returns: The Wialon id for the new user, if it was created.
20
21
  :rtype: :py:obj:`int` | :py:obj:`None`
21
22
 
22
23
  """
23
- if not kwargs.get("creator_id"):
24
- raise ValueError("'creator_id' is required on creation.")
25
- if not kwargs.get("name"):
26
- raise ValueError("'name' is required on creation.")
27
- if not kwargs.get("password"):
28
- raise ValueError("'password' is required on creation.")
24
+ if isinstance(creator_id, str) and not creator_id.isdigit():
25
+ raise ValueError(f"'creator_id' must be a digit, got '{creator_id}'.")
29
26
 
30
27
  response = self.session.wialon_api.core_create_user(
31
28
  **{
32
- "creatorId": kwargs["creator_id"],
33
- "name": kwargs["name"],
34
- "password": kwargs["password"],
29
+ "creatorId": creator_id,
30
+ "name": name,
31
+ "password": password,
35
32
  "dataFlags": flags.DATAFLAG_UNIT_BASE,
36
33
  }
37
34
  )
38
- return response.get("item", {}).get("id")
35
+ return int(response.get("item", {}).get("id")) if response.get("item") else None
39
36
 
40
37
  def _get_access_response(self, hw_type: str) -> dict:
41
38
  """
@@ -504,7 +504,7 @@ wheels = [
504
504
 
505
505
  [[package]]
506
506
  name = "python-terminusgps"
507
- version = "1.17.1"
507
+ version = "1.18.0"
508
508
  source = { editable = "." }
509
509
  dependencies = [
510
510
  { name = "argparse" },
@@ -1,21 +0,0 @@
1
- from terminusgps.wialon import flags
2
- from terminusgps.wialon.items.base import WialonBase
3
-
4
-
5
- class WialonRoute(WialonBase):
6
- def create(self, **kwargs) -> int | None:
7
- if not kwargs.get("creator_id"):
8
- raise ValueError("'creator_id' is required on creation.")
9
- if not kwargs.get("name"):
10
- raise ValueError("'name' is required on creation.")
11
- if not kwargs.get("flags"):
12
- kwargs["flags"] = flags.DATAFLAG_UNIT_BASE
13
-
14
- response = self.session.wialon_api.core_create_route(
15
- **{
16
- "creatorId": kwargs["creator_id"],
17
- "name": kwargs["name"],
18
- "dataFlags": kwargs["flags"],
19
- }
20
- )
21
- return response.get("item", {}).get("id")