Habiticalib 0.3.5__py3-none-any.whl → 0.3.6__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.
habiticalib/const.py CHANGED
@@ -1,6 +1,6 @@
1
1
  """Constants for Habiticalib."""
2
2
 
3
- __version__ = "0.3.5"
3
+ __version__ = "0.3.6"
4
4
 
5
5
  DEFAULT_URL = "https://habitica.com/"
6
6
  ASSETS_URL = "https://habitica-assets.s3.amazonaws.com/mobileApp/images/"
habiticalib/types.py CHANGED
@@ -703,17 +703,48 @@ class PushDevicesUser:
703
703
  updatedAt: datetime
704
704
 
705
705
 
706
+ class WebhooksType(StrEnum):
707
+ """Webhook types."""
708
+
709
+ TASK_ACTIVITY = "taskActivity"
710
+ USER_ACTIVITY = "userActivity"
711
+ QUEST_ACTIVITY = "questActivity"
712
+ GROUP_CHAT_RECEIVED = "groupChatReceived"
713
+
714
+
715
+ @dataclass(kw_only=True)
716
+ class WebhooksOptions:
717
+ """Webhooks options data."""
718
+
719
+ created: bool | None = None
720
+ updated: bool | None = None
721
+ deleted: bool | None = None
722
+ scored: bool | None = None
723
+ questStarted: bool | None = None
724
+ questFinished: bool | None = None
725
+ questInvited: bool | None = None
726
+ petHatched: bool | None = None
727
+ mountRaised: bool | None = None
728
+ leveledUp: bool | None = None
729
+ groupId: UUID | None = None
730
+
731
+
706
732
  @dataclass(kw_only=True)
707
733
  class WebhooksUser:
708
734
  """Webhooks user data."""
709
735
 
710
- id: UUID
711
- Type: str = field(metadata=field_options(alias="type"))
712
- label: str
713
- url: str
714
- enabled: bool
715
- failures: int
716
- lastFailureAt: datetime | None
736
+ id: UUID | None = None
737
+ Type: WebhooksType = field(
738
+ metadata=field_options(alias="type"), default=WebhooksType.TASK_ACTIVITY
739
+ )
740
+ url: str | None = None
741
+ enabled: bool = True
742
+ failures: int = 0
743
+ label: str = ""
744
+ options = WebhooksOptions
745
+ lastFailureAt: datetime | None = None
746
+ createdAt: datetime | None = None
747
+ updatedAt: datetime | None = None
717
748
 
718
749
 
719
750
  @dataclass(kw_only=True)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: Habiticalib
3
- Version: 0.3.5
3
+ Version: 0.3.6
4
4
  Summary: Asynchronous Python client library for the Habitica API
5
5
  Project-URL: Documentation, https://tr4nt0r.github.io/habiticalib/
6
6
  Project-URL: Source, https://github.com/tr4nt0r/habiticalib
@@ -1,12 +1,12 @@
1
1
  habiticalib/__init__.py,sha256=YDYsEGMIxZftYU9YkNC0tyvJrkxn2lXV8WcVQoOXyvA,2415
2
- habiticalib/const.py,sha256=QvfUFP2ql8iTm2-36g-NC4GSWlYsWciYVWQ0uhMsABk,2308
2
+ habiticalib/const.py,sha256=MVr38-2gSv2INTDYj9JAZRnIEYZZSkYn5ky6TKHQwQw,2308
3
3
  habiticalib/exceptions.py,sha256=oVFCGbHkVn0UpIKIPZPzXfvzs9US4R05ebdEn6cOpqM,1350
4
4
  habiticalib/ha.py,sha256=rSzrs7ixLJH3ZtOFlcuKV2t1ZndT0VpuPhDsGqorkOs,20757
5
5
  habiticalib/helpers.py,sha256=IRZLYWkDVLI0iVBgBMmvZ6L83KCUl-CnzGhUR_tP6Fg,4576
6
6
  habiticalib/lib.py,sha256=YxnlRwCsSlmrdvVu06TKRa6SgnQj2fh2LY8JM7HRqq8,73610
7
7
  habiticalib/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
8
- habiticalib/types.py,sha256=svPW9SHUNTDp8zuXahhFH__3ioy4O8RHiUlkzdd0_dk,43529
9
- habiticalib-0.3.5.dist-info/METADATA,sha256=E5Rbx47jsOa6T4oSBxosipxDiO0n4V7Ey0AZL2RCzvM,4207
10
- habiticalib-0.3.5.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
11
- habiticalib-0.3.5.dist-info/licenses/LICENSE,sha256=oIinIOSJ49l1iVIRI3XGXFWt6SF7a83kEFBAY8ORwNI,1084
12
- habiticalib-0.3.5.dist-info/RECORD,,
8
+ habiticalib/types.py,sha256=oFf70uTTgj1qE9USKwjI5osEApJQ_XInXZ9TDabkfVc,44415
9
+ habiticalib-0.3.6.dist-info/METADATA,sha256=2rGeYZZnO1JKCWfbWkzbHwk_mJKEhelpN-RcvtpYoqA,4207
10
+ habiticalib-0.3.6.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
11
+ habiticalib-0.3.6.dist-info/licenses/LICENSE,sha256=oIinIOSJ49l1iVIRI3XGXFWt6SF7a83kEFBAY8ORwNI,1084
12
+ habiticalib-0.3.6.dist-info/RECORD,,