PyGithub-asyncio 3.0.0b1__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.
Files changed (188) hide show
  1. githubasyncio/AccessToken.py +159 -0
  2. githubasyncio/AdvisoryBase.py +163 -0
  3. githubasyncio/AdvisoryCredit.py +131 -0
  4. githubasyncio/AdvisoryCreditDetailed.py +110 -0
  5. githubasyncio/AdvisoryVulnerability.py +191 -0
  6. githubasyncio/AdvisoryVulnerabilityPackage.py +93 -0
  7. githubasyncio/AppAuthentication.py +58 -0
  8. githubasyncio/ApplicationOAuth.py +200 -0
  9. githubasyncio/Artifact.py +183 -0
  10. githubasyncio/Auth.py +560 -0
  11. githubasyncio/AuthenticatedUser.py +1251 -0
  12. githubasyncio/Authorization.py +192 -0
  13. githubasyncio/AuthorizationApplication.py +73 -0
  14. githubasyncio/Autolink.py +104 -0
  15. githubasyncio/Branch.py +689 -0
  16. githubasyncio/BranchProtection.py +224 -0
  17. githubasyncio/CVSS.py +83 -0
  18. githubasyncio/CWE.py +75 -0
  19. githubasyncio/CheckRun.py +315 -0
  20. githubasyncio/CheckRunAnnotation.py +134 -0
  21. githubasyncio/CheckRunOutput.py +108 -0
  22. githubasyncio/CheckSuite.py +319 -0
  23. githubasyncio/Clones.py +97 -0
  24. githubasyncio/CodeScanAlert.py +215 -0
  25. githubasyncio/CodeScanAlertInstance.py +134 -0
  26. githubasyncio/CodeScanAlertInstanceLocation.py +102 -0
  27. githubasyncio/CodeScanRule.py +134 -0
  28. githubasyncio/CodeScanTool.py +94 -0
  29. githubasyncio/CodeSecurityConfig.py +301 -0
  30. githubasyncio/CodeSecurityConfigRepository.py +70 -0
  31. githubasyncio/Commit.py +442 -0
  32. githubasyncio/CommitCombinedStatus.py +126 -0
  33. githubasyncio/CommitComment.py +270 -0
  34. githubasyncio/CommitStats.py +78 -0
  35. githubasyncio/CommitStatus.py +169 -0
  36. githubasyncio/Comparison.py +219 -0
  37. githubasyncio/Consts.py +197 -0
  38. githubasyncio/ContentFile.py +304 -0
  39. githubasyncio/Copilot.py +97 -0
  40. githubasyncio/CopilotSeat.py +132 -0
  41. githubasyncio/DefaultCodeSecurityConfig.py +93 -0
  42. githubasyncio/DependabotAlert.py +184 -0
  43. githubasyncio/DependabotAlertAdvisory.py +82 -0
  44. githubasyncio/DependabotAlertDependency.py +100 -0
  45. githubasyncio/DependabotAlertVulnerability.py +85 -0
  46. githubasyncio/Deployment.py +314 -0
  47. githubasyncio/DeploymentBranchPolicy.py +102 -0
  48. githubasyncio/DeploymentStatus.py +201 -0
  49. githubasyncio/DiscussionBase.py +140 -0
  50. githubasyncio/DiscussionCommentBase.py +140 -0
  51. githubasyncio/Download.py +256 -0
  52. githubasyncio/Enterprise.py +175 -0
  53. githubasyncio/EnterpriseConsumedLicenses.py +138 -0
  54. githubasyncio/Environment.py +354 -0
  55. githubasyncio/EnvironmentDeploymentBranchPolicy.py +87 -0
  56. githubasyncio/EnvironmentProtectionRule.py +117 -0
  57. githubasyncio/EnvironmentProtectionRuleReviewer.py +110 -0
  58. githubasyncio/Event.py +134 -0
  59. githubasyncio/File.py +142 -0
  60. githubasyncio/GeneratedReleaseNotes.py +68 -0
  61. githubasyncio/Gist.py +373 -0
  62. githubasyncio/GistComment.py +162 -0
  63. githubasyncio/GistFile.py +106 -0
  64. githubasyncio/GistHistoryState.py +245 -0
  65. githubasyncio/GitAuthor.py +94 -0
  66. githubasyncio/GitBlob.py +123 -0
  67. githubasyncio/GitCommit.py +208 -0
  68. githubasyncio/GitCommitVerification.py +103 -0
  69. githubasyncio/GitObject.py +84 -0
  70. githubasyncio/GitRef.py +122 -0
  71. githubasyncio/GitRelease.py +476 -0
  72. githubasyncio/GitReleaseAsset.py +232 -0
  73. githubasyncio/GitTag.py +143 -0
  74. githubasyncio/GitTree.py +113 -0
  75. githubasyncio/GitTreeElement.py +104 -0
  76. githubasyncio/GithubApp.py +236 -0
  77. githubasyncio/GithubException.py +226 -0
  78. githubasyncio/GithubIntegration.py +365 -0
  79. githubasyncio/GithubObject.py +910 -0
  80. githubasyncio/GithubRetry.py +253 -0
  81. githubasyncio/GitignoreTemplate.py +88 -0
  82. githubasyncio/GlobalAdvisory.py +141 -0
  83. githubasyncio/Hook.py +238 -0
  84. githubasyncio/HookDelivery.py +243 -0
  85. githubasyncio/HookDescription.py +85 -0
  86. githubasyncio/HookResponse.py +83 -0
  87. githubasyncio/InputFileContent.py +63 -0
  88. githubasyncio/InputGitAuthor.py +71 -0
  89. githubasyncio/InputGitTreeElement.py +79 -0
  90. githubasyncio/Installation.py +298 -0
  91. githubasyncio/InstallationAuthorization.py +138 -0
  92. githubasyncio/Invitation.py +171 -0
  93. githubasyncio/Issue.py +955 -0
  94. githubasyncio/IssueComment.py +309 -0
  95. githubasyncio/IssueDependenciesSummary.py +77 -0
  96. githubasyncio/IssueEvent.py +296 -0
  97. githubasyncio/IssuePullRequest.py +97 -0
  98. githubasyncio/IssueType.py +123 -0
  99. githubasyncio/Label.py +186 -0
  100. githubasyncio/License.py +169 -0
  101. githubasyncio/MainClass.py +1142 -0
  102. githubasyncio/Membership.py +154 -0
  103. githubasyncio/MergedUpstream.py +71 -0
  104. githubasyncio/Migration.py +281 -0
  105. githubasyncio/Milestone.py +255 -0
  106. githubasyncio/NamedEnterpriseUser.py +207 -0
  107. githubasyncio/NamedUser.py +841 -0
  108. githubasyncio/Notification.py +182 -0
  109. githubasyncio/NotificationSubject.py +96 -0
  110. githubasyncio/Organization.py +2462 -0
  111. githubasyncio/OrganizationCodeScanAlert.py +65 -0
  112. githubasyncio/OrganizationCustomProperty.py +215 -0
  113. githubasyncio/OrganizationDependabotAlert.py +75 -0
  114. githubasyncio/OrganizationSecret.py +191 -0
  115. githubasyncio/OrganizationSecretScanAlert.py +112 -0
  116. githubasyncio/OrganizationVariable.py +141 -0
  117. githubasyncio/PaginatedList.py +652 -0
  118. githubasyncio/Path.py +102 -0
  119. githubasyncio/Permissions.py +113 -0
  120. githubasyncio/Plan.py +108 -0
  121. githubasyncio/Project.py +286 -0
  122. githubasyncio/ProjectCard.py +257 -0
  123. githubasyncio/ProjectColumn.py +227 -0
  124. githubasyncio/PublicKey.py +138 -0
  125. githubasyncio/PullRequest.py +1202 -0
  126. githubasyncio/PullRequestComment.py +401 -0
  127. githubasyncio/PullRequestMergeStatus.py +89 -0
  128. githubasyncio/PullRequestPart.py +110 -0
  129. githubasyncio/PullRequestReview.py +214 -0
  130. githubasyncio/Rate.py +123 -0
  131. githubasyncio/RateLimit.py +210 -0
  132. githubasyncio/RateLimitOverview.py +104 -0
  133. githubasyncio/Reaction.py +128 -0
  134. githubasyncio/Referrer.py +94 -0
  135. githubasyncio/RepoCodeSecurityConfig.py +93 -0
  136. githubasyncio/Repository.py +5211 -0
  137. githubasyncio/RepositoryAdvisory.py +431 -0
  138. githubasyncio/RepositoryDiscussion.py +221 -0
  139. githubasyncio/RepositoryDiscussionCategory.py +150 -0
  140. githubasyncio/RepositoryDiscussionComment.py +159 -0
  141. githubasyncio/RepositoryKey.py +166 -0
  142. githubasyncio/RepositoryPreferences.py +82 -0
  143. githubasyncio/RepositoryRulesetBypassActor.py +75 -0
  144. githubasyncio/Requester.py +1518 -0
  145. githubasyncio/RequiredPullRequestReviews.py +269 -0
  146. githubasyncio/RequiredStatusChecks.py +153 -0
  147. githubasyncio/Rule.py +134 -0
  148. githubasyncio/Ruleset.py +292 -0
  149. githubasyncio/Secret.py +139 -0
  150. githubasyncio/SecretScanAlert.py +317 -0
  151. githubasyncio/SecretScanAlertInstance.py +128 -0
  152. githubasyncio/SecurityAndAnalysis.py +188 -0
  153. githubasyncio/SecurityAndAnalysisFeature.py +79 -0
  154. githubasyncio/SelfHostedActionsRunner.py +129 -0
  155. githubasyncio/SelfHostedActionsRunnerApplication.py +92 -0
  156. githubasyncio/SelfHostedActionsRunnerJitConfig.py +74 -0
  157. githubasyncio/SelfHostedActionsRunnerToken.py +118 -0
  158. githubasyncio/SourceImport.py +260 -0
  159. githubasyncio/Stargazer.py +88 -0
  160. githubasyncio/StatsCodeFrequency.py +81 -0
  161. githubasyncio/StatsCommitActivity.py +86 -0
  162. githubasyncio/StatsContributor.py +138 -0
  163. githubasyncio/StatsParticipation.py +78 -0
  164. githubasyncio/StatsPunchCard.py +76 -0
  165. githubasyncio/SubIssueSummary.py +70 -0
  166. githubasyncio/Tag.py +108 -0
  167. githubasyncio/Team.py +618 -0
  168. githubasyncio/TeamDiscussion.py +137 -0
  169. githubasyncio/TimelineEvent.py +164 -0
  170. githubasyncio/TimelineEventSource.py +81 -0
  171. githubasyncio/Topic.py +177 -0
  172. githubasyncio/Traffic.py +95 -0
  173. githubasyncio/UserKey.py +141 -0
  174. githubasyncio/Variable.py +155 -0
  175. githubasyncio/View.py +97 -0
  176. githubasyncio/Workflow.py +335 -0
  177. githubasyncio/WorkflowJob.py +253 -0
  178. githubasyncio/WorkflowRun.py +480 -0
  179. githubasyncio/WorkflowStep.py +118 -0
  180. githubasyncio/__init__.py +38 -0
  181. githubasyncio/compat/__init__.py +52 -0
  182. githubasyncio/requestlib/__init__.py +29 -0
  183. pygithub_asyncio-3.0.0b1.dist-info/METADATA +102 -0
  184. pygithub_asyncio-3.0.0b1.dist-info/RECORD +188 -0
  185. pygithub_asyncio-3.0.0b1.dist-info/WHEEL +5 -0
  186. pygithub_asyncio-3.0.0b1.dist-info/licenses/COPYING +674 -0
  187. pygithub_asyncio-3.0.0b1.dist-info/licenses/COPYING.LESSER +165 -0
  188. pygithub_asyncio-3.0.0b1.dist-info/top_level.txt +1 -0
@@ -0,0 +1,137 @@
1
+ # FILE AUTO GENERATED DO NOT TOUCH
2
+ ############################ Copyrights and license ############################
3
+ # #
4
+ # Copyright 2012 Vincent Jacques <vincent@vincent-jacques.net> #
5
+ # Copyright 2012 Zearin <zearin@gonk.net> #
6
+ # Copyright 2013 AKFish <akfish@gmail.com> #
7
+ # Copyright 2013 Vincent Jacques <vincent@vincent-jacques.net> #
8
+ # Copyright 2014 Vincent Jacques <vincent@vincent-jacques.net> #
9
+ # Copyright 2016 Jannis Gebauer <ja.geb@me.com> #
10
+ # Copyright 2016 Peter Buckley <dx-pbuckley@users.noreply.github.com> #
11
+ # Copyright 2017 Chris McBride <thehighlander@users.noreply.github.com> #
12
+ # Copyright 2017 Simon <spam@esemi.ru> #
13
+ # Copyright 2018 Benoit Latinier <benoit@latinier.fr> #
14
+ # Copyright 2018 Wan Liuyang <tsfdye@gmail.com> #
15
+ # Copyright 2018 Yossarian King <yggy@blackbirdinteractive.com> #
16
+ # Copyright 2018 sfdye <tsfdye@gmail.com> #
17
+ # Copyright 2019 Adam Baratz <adam.baratz@gmail.com> #
18
+ # Copyright 2019 Steve Kowalik <steven@wedontsleep.org> #
19
+ # Copyright 2019 Wan Liuyang <tsfdye@gmail.com> #
20
+ # Copyright 2020 Steve Kowalik <steven@wedontsleep.org> #
21
+ # Copyright 2021 Steve Kowalik <steven@wedontsleep.org> #
22
+ # Copyright 2023 Enrico Minack <github@enrico.minack.dev> #
23
+ # Copyright 2023 Jirka Borovec <6035284+Borda@users.noreply.github.com> #
24
+ # Copyright 2023 Trim21 <trim21.me@gmail.com> #
25
+ # Copyright 2024 Enrico Minack <github@enrico.minack.dev> #
26
+ # Copyright 2024 Jirka Borovec <6035284+Borda@users.noreply.github.com> #
27
+ # Copyright 2025 Enrico Minack <github@enrico.minack.dev> #
28
+ # Copyright 2026 Enrico Minack <github@enrico.minack.dev> #
29
+ # #
30
+ # This file is part of PyGithub. #
31
+ # http://pygithub.readthedocs.io/ #
32
+ # #
33
+ # PyGithub is free software: you can redistribute it and/or modify it under #
34
+ # the terms of the GNU Lesser General Public License as published by the Free #
35
+ # Software Foundation, either version 3 of the License, or (at your option) #
36
+ # any later version. #
37
+ # #
38
+ # PyGithub is distributed in the hope that it will be useful, but WITHOUT ANY #
39
+ # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS #
40
+ # FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more #
41
+ # details. #
42
+ # #
43
+ # You should have received a copy of the GNU Lesser General Public License #
44
+ # along with PyGithub. If not, see <http://www.gnu.org/licenses/>. #
45
+ # #
46
+ ################################################################################
47
+
48
+ from __future__ import annotations
49
+
50
+ from typing import Any
51
+
52
+ from githubasyncio.DiscussionBase import DiscussionBase
53
+ from githubasyncio.GithubObject import Attribute, NotSet
54
+
55
+
56
+ class TeamDiscussion(DiscussionBase):
57
+ """
58
+ This class represents TeamDiscussions.
59
+
60
+ The reference can be found here
61
+ https://docs.github.com/en/rest/reference/teams#discussions
62
+
63
+ The OpenAPI schema can be found at
64
+
65
+ - /components/schemas/team-discussion
66
+
67
+ """
68
+
69
+ def _initAttributes(self) -> None:
70
+ super()._initAttributes()
71
+ self._body_version: Attribute[str] = NotSet
72
+ self._comments_count: Attribute[int] = NotSet
73
+ self._comments_url: Attribute[str] = NotSet
74
+ self._html_url: Attribute[str] = NotSet
75
+ self._node_id: Attribute[str] = NotSet
76
+ self._pinned: Attribute[bool] = NotSet
77
+ self._private: Attribute[bool] = NotSet
78
+ self._team_url: Attribute[str] = NotSet
79
+
80
+ @property
81
+ async def body_version(self) -> str:
82
+ await self._completeIfNotSet(self._body_version)
83
+ return self._body_version.value
84
+
85
+ @property
86
+ async def comments_count(self) -> int:
87
+ await self._completeIfNotSet(self._comments_count)
88
+ return self._comments_count.value
89
+
90
+ @property
91
+ async def comments_url(self) -> str:
92
+ await self._completeIfNotSet(self._comments_url)
93
+ return self._comments_url.value
94
+
95
+ @property
96
+ async def html_url(self) -> str:
97
+ await self._completeIfNotSet(self._html_url)
98
+ return self._html_url.value
99
+
100
+ @property
101
+ async def node_id(self) -> str:
102
+ await self._completeIfNotSet(self._node_id)
103
+ return self._node_id.value
104
+
105
+ @property
106
+ async def pinned(self) -> bool:
107
+ await self._completeIfNotSet(self._pinned)
108
+ return self._pinned.value
109
+
110
+ @property
111
+ async def private(self) -> bool:
112
+ await self._completeIfNotSet(self._private)
113
+ return self._private.value
114
+
115
+ @property
116
+ async def team_url(self) -> str:
117
+ await self._completeIfNotSet(self._team_url)
118
+ return self._team_url.value
119
+
120
+ def _useAttributes(self, attributes: dict[str, Any]) -> None:
121
+ super()._useAttributes(attributes)
122
+ if "body_version" in attributes: # pragma no branch
123
+ self._body_version = self._makeStringAttribute(attributes["body_version"])
124
+ if "comments_count" in attributes: # pragma no branch
125
+ self._comments_count = self._makeIntAttribute(attributes["comments_count"])
126
+ if "comments_url" in attributes: # pragma no branch
127
+ self._comments_url = self._makeStringAttribute(attributes["comments_url"])
128
+ if "html_url" in attributes: # pragma no branch
129
+ self._html_url = self._makeStringAttribute(attributes["html_url"])
130
+ if "node_id" in attributes: # pragma no branch
131
+ self._node_id = self._makeStringAttribute(attributes["node_id"])
132
+ if "pinned" in attributes: # pragma no branch
133
+ self._pinned = self._makeBoolAttribute(attributes["pinned"])
134
+ if "private" in attributes: # pragma no branch
135
+ self._private = self._makeBoolAttribute(attributes["private"])
136
+ if "team_url" in attributes: # pragma no branch
137
+ self._team_url = self._makeStringAttribute(attributes["team_url"])
@@ -0,0 +1,164 @@
1
+ # FILE AUTO GENERATED DO NOT TOUCH
2
+ ############################ Copyrights and license ############################
3
+ # #
4
+ # Copyright 2012 Vincent Jacques <vincent@vincent-jacques.net> #
5
+ # Copyright 2012 Zearin <zearin@gonk.net> #
6
+ # Copyright 2013 AKFish <akfish@gmail.com> #
7
+ # Copyright 2013 Vincent Jacques <vincent@vincent-jacques.net> #
8
+ # Copyright 2014 Vincent Jacques <vincent@vincent-jacques.net> #
9
+ # Copyright 2016 Jannis Gebauer <ja.geb@me.com> #
10
+ # Copyright 2016 Peter Buckley <dx-pbuckley@users.noreply.github.com> #
11
+ # Copyright 2017 Aaron Levine <allevin@sandia.gov> #
12
+ # Copyright 2017 Mike Miller <github@mikeage.net> #
13
+ # Copyright 2018 Darragh Bailey <daragh.bailey@gmail.com> #
14
+ # Copyright 2018 Wan Liuyang <tsfdye@gmail.com> #
15
+ # Copyright 2018 sfdye <tsfdye@gmail.com> #
16
+ # Copyright 2019 Nick Campbell <nicholas.j.campbell@gmail.com> #
17
+ # Copyright 2019 Steve Kowalik <steven@wedontsleep.org> #
18
+ # Copyright 2019 Wan Liuyang <tsfdye@gmail.com> #
19
+ # Copyright 2020 Steve Kowalik <steven@wedontsleep.org> #
20
+ # Copyright 2021 Steve Kowalik <steven@wedontsleep.org> #
21
+ # Copyright 2023 Enrico Minack <github@enrico.minack.dev> #
22
+ # Copyright 2023 Jirka Borovec <6035284+Borda@users.noreply.github.com> #
23
+ # Copyright 2023 Trim21 <trim21.me@gmail.com> #
24
+ # Copyright 2024 Enrico Minack <github@enrico.minack.dev> #
25
+ # Copyright 2024 Jirka Borovec <6035284+Borda@users.noreply.github.com> #
26
+ # Copyright 2025 Enrico Minack <github@enrico.minack.dev> #
27
+ # Copyright 2026 Enrico Minack <github@enrico.minack.dev> #
28
+ # #
29
+ # This file is part of PyGithub. #
30
+ # http://pygithub.readthedocs.io/ #
31
+ # #
32
+ # PyGithub is free software: you can redistribute it and/or modify it under #
33
+ # the terms of the GNU Lesser General Public License as published by the Free #
34
+ # Software Foundation, either version 3 of the License, or (at your option) #
35
+ # any later version. #
36
+ # #
37
+ # PyGithub is distributed in the hope that it will be useful, but WITHOUT ANY #
38
+ # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS #
39
+ # FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more #
40
+ # details. #
41
+ # #
42
+ # You should have received a copy of the GNU Lesser General Public License #
43
+ # along with PyGithub. If not, see <http://www.gnu.org/licenses/>. #
44
+ # #
45
+ ################################################################################
46
+
47
+ from __future__ import annotations
48
+
49
+ from datetime import datetime
50
+ from typing import TYPE_CHECKING, Any
51
+
52
+ import githubasyncio.GithubObject
53
+ import githubasyncio.NamedUser
54
+ import githubasyncio.TimelineEventSource
55
+ from githubasyncio.GithubObject import Attribute, NonCompletableGithubObject, NotSet, is_defined
56
+
57
+ if TYPE_CHECKING:
58
+ from githubasyncio.NamedUser import NamedUser
59
+ from githubasyncio.TimelineEventSource import TimelineEventSource
60
+
61
+
62
+ class TimelineEvent(NonCompletableGithubObject):
63
+ """
64
+ This class represents IssueTimelineEvents.
65
+
66
+ The reference can be found here
67
+ https://docs.github.com/en/rest/reference/issues#timeline
68
+
69
+ The OpenAPI schema can be found at
70
+
71
+ - /components/schemas/timeline-issue-events
72
+
73
+ """
74
+
75
+ def _initAttributes(self) -> None:
76
+ self._actor: Attribute[NamedUser] = NotSet
77
+ self._commit_id: Attribute[str] = NotSet
78
+ self._commit_url: Attribute[str] = NotSet
79
+ self._created_at: Attribute[datetime] = NotSet
80
+ self._event: Attribute[str] = NotSet
81
+ self._id: Attribute[int] = NotSet
82
+ self._node_id: Attribute[str] = NotSet
83
+ self._source: Attribute[TimelineEventSource] = NotSet
84
+ self._url: Attribute[str] = NotSet
85
+
86
+ def __repr__(self) -> str:
87
+ return self.get__repr__({"id": self._id.value})
88
+
89
+ @property
90
+ def actor(self) -> NamedUser:
91
+ return self._actor.value
92
+
93
+ @property
94
+ def author_association(self) -> str | None:
95
+ if self.event == "commented" and is_defined(self._author_association):
96
+ return self._author_association.value
97
+ return None
98
+
99
+ @property
100
+ def body(self) -> str | None:
101
+ if self.event == "commented" and is_defined(self._body):
102
+ return self._body.value
103
+ return None
104
+
105
+ @property
106
+ def commit_id(self) -> str:
107
+ return self._commit_id.value
108
+
109
+ @property
110
+ def commit_url(self) -> str:
111
+ return self._commit_url.value
112
+
113
+ @property
114
+ def created_at(self) -> datetime:
115
+ return self._created_at.value
116
+
117
+ @property
118
+ def event(self) -> str:
119
+ return self._event.value
120
+
121
+ @property
122
+ def id(self) -> int:
123
+ return self._id.value
124
+
125
+ @property
126
+ def node_id(self) -> str:
127
+ return self._node_id.value
128
+
129
+ @property
130
+ def source(self) -> TimelineEventSource | None:
131
+ # only available on `cross-referenced` events.
132
+ if self.event == "cross-referenced" and is_defined(self._source):
133
+ return self._source.value
134
+ return None
135
+
136
+ @property
137
+ def url(self) -> str:
138
+ return self._url.value
139
+
140
+ def _useAttributes(self, attributes: dict[str, Any]) -> None:
141
+ if "actor" in attributes: # pragma no branch
142
+ self._actor = self._makeClassAttribute(githubasyncio.NamedUser.NamedUser, attributes["actor"])
143
+ if "author_association" in attributes: # pragma no branch
144
+ self._author_association = self._makeStringAttribute(attributes["author_association"])
145
+ if "body" in attributes: # pragma no branch
146
+ self._body = self._makeStringAttribute(attributes["body"])
147
+ if "commit_id" in attributes: # pragma no branch
148
+ self._commit_id = self._makeStringAttribute(attributes["commit_id"])
149
+ if "commit_url" in attributes: # pragma no branch
150
+ self._commit_url = self._makeStringAttribute(attributes["commit_url"])
151
+ if "created_at" in attributes: # pragma no branch
152
+ self._created_at = self._makeDatetimeAttribute(attributes["created_at"])
153
+ if "event" in attributes: # pragma no branch
154
+ self._event = self._makeStringAttribute(attributes["event"])
155
+ if "id" in attributes: # pragma no branch
156
+ self._id = self._makeIntAttribute(attributes["id"])
157
+ if "node_id" in attributes: # pragma no branch
158
+ self._node_id = self._makeStringAttribute(attributes["node_id"])
159
+ if "source" in attributes: # pragma no branch
160
+ self._source = self._makeClassAttribute(
161
+ githubasyncio.TimelineEventSource.TimelineEventSource, attributes["source"]
162
+ )
163
+ if "url" in attributes: # pragma no branch
164
+ self._url = self._makeStringAttribute(attributes["url"])
@@ -0,0 +1,81 @@
1
+ # FILE AUTO GENERATED DO NOT TOUCH
2
+ ############################ Copyrights and license ############################
3
+ # #
4
+ # Copyright 2012 Vincent Jacques <vincent@vincent-jacques.net> #
5
+ # Copyright 2012 Zearin <zearin@gonk.net> #
6
+ # Copyright 2013 Vincent Jacques <vincent@vincent-jacques.net> #
7
+ # Copyright 2014 Vincent Jacques <vincent@vincent-jacques.net> #
8
+ # Copyright 2016 Peter Buckley <dx-pbuckley@users.noreply.github.com> #
9
+ # Copyright 2018 Wan Liuyang <tsfdye@gmail.com> #
10
+ # Copyright 2018 sfdye <tsfdye@gmail.com> #
11
+ # Copyright 2019 Adam Baratz <adam.baratz@gmail.com> #
12
+ # Copyright 2019 Nick Campbell <nicholas.j.campbell@gmail.com> #
13
+ # Copyright 2019 Steve Kowalik <steven@wedontsleep.org> #
14
+ # Copyright 2019 Wan Liuyang <tsfdye@gmail.com> #
15
+ # Copyright 2020 Steve Kowalik <steven@wedontsleep.org> #
16
+ # Copyright 2021 Steve Kowalik <steven@wedontsleep.org> #
17
+ # Copyright 2023 Enrico Minack <github@enrico.minack.dev> #
18
+ # Copyright 2023 Jirka Borovec <6035284+Borda@users.noreply.github.com> #
19
+ # Copyright 2023 Trim21 <trim21.me@gmail.com> #
20
+ # Copyright 2024 Enrico Minack <github@enrico.minack.dev> #
21
+ # Copyright 2024 Jirka Borovec <6035284+Borda@users.noreply.github.com> #
22
+ # Copyright 2025 Enrico Minack <github@enrico.minack.dev> #
23
+ # #
24
+ # This file is part of PyGithub. #
25
+ # http://pygithub.readthedocs.io/ #
26
+ # #
27
+ # PyGithub is free software: you can redistribute it and/or modify it under #
28
+ # the terms of the GNU Lesser General Public License as published by the Free #
29
+ # Software Foundation, either version 3 of the License, or (at your option) #
30
+ # any later version. #
31
+ # #
32
+ # PyGithub is distributed in the hope that it will be useful, but WITHOUT ANY #
33
+ # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS #
34
+ # FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more #
35
+ # details. #
36
+ # #
37
+ # You should have received a copy of the GNU Lesser General Public License #
38
+ # along with PyGithub. If not, see <http://www.gnu.org/licenses/>. #
39
+ # #
40
+ ################################################################################
41
+
42
+ from __future__ import annotations
43
+
44
+ from typing import TYPE_CHECKING, Any
45
+
46
+ import githubasyncio.Issue
47
+ from githubasyncio.GithubObject import Attribute, NonCompletableGithubObject, NotSet
48
+
49
+ if TYPE_CHECKING:
50
+ from githubasyncio.Issue import Issue
51
+
52
+
53
+ class TimelineEventSource(NonCompletableGithubObject):
54
+ """
55
+ This class represents IssueTimelineEventSource.
56
+
57
+ The reference can be found here
58
+ https://docs.github.com/en/rest/reference/issues#timeline
59
+
60
+ """
61
+
62
+ def _initAttributes(self) -> None:
63
+ self._issue: Attribute[Issue] = NotSet
64
+ self._type: Attribute[str] = NotSet
65
+
66
+ def __repr__(self) -> str:
67
+ return self.get__repr__({"type": self._type.value})
68
+
69
+ @property
70
+ def issue(self) -> Issue:
71
+ return self._issue.value
72
+
73
+ @property
74
+ def type(self) -> str:
75
+ return self._type.value
76
+
77
+ def _useAttributes(self, attributes: dict[str, Any]) -> None:
78
+ if "issue" in attributes: # pragma no branch
79
+ self._issue = self._makeClassAttribute(githubasyncio.Issue.Issue, attributes["issue"])
80
+ if "type" in attributes: # pragma no branch
81
+ self._type = self._makeStringAttribute(attributes["type"])
githubasyncio/Topic.py ADDED
@@ -0,0 +1,177 @@
1
+ # FILE AUTO GENERATED DO NOT TOUCH
2
+ ############################ Copyrights and license ############################
3
+ # #
4
+ # Copyright 2012 Vincent Jacques <vincent@vincent-jacques.net> #
5
+ # Copyright 2012 Zearin <zearin@gonk.net> #
6
+ # Copyright 2013 AKFish <akfish@gmail.com> #
7
+ # Copyright 2013 Vincent Jacques <vincent@vincent-jacques.net> #
8
+ # Copyright 2014 Vincent Jacques <vincent@vincent-jacques.net> #
9
+ # Copyright 2016 Jannis Gebauer <ja.geb@me.com> #
10
+ # Copyright 2016 Peter Buckley <dx-pbuckley@users.noreply.github.com> #
11
+ # Copyright 2018 Steve Kowalik <steven@wedontsleep.org> #
12
+ # Copyright 2018 Wan Liuyang <tsfdye@gmail.com> #
13
+ # Copyright 2018 sfdye <tsfdye@gmail.com> #
14
+ # Copyright 2019 Adam Baratz <adam.baratz@gmail.com> #
15
+ # Copyright 2019 Steve Kowalik <steven@wedontsleep.org> #
16
+ # Copyright 2019 Wan Liuyang <tsfdye@gmail.com> #
17
+ # Copyright 2020 Steve Kowalik <steven@wedontsleep.org> #
18
+ # Copyright 2021 Steve Kowalik <steven@wedontsleep.org> #
19
+ # Copyright 2023 Enrico Minack <github@enrico.minack.dev> #
20
+ # Copyright 2023 Jirka Borovec <6035284+Borda@users.noreply.github.com> #
21
+ # Copyright 2023 Trim21 <trim21.me@gmail.com> #
22
+ # Copyright 2025 Enrico Minack <github@enrico.minack.dev> #
23
+ # #
24
+ # This file is part of PyGithub. #
25
+ # http://pygithub.readthedocs.io/ #
26
+ # #
27
+ # PyGithub is free software: you can redistribute it and/or modify it under #
28
+ # the terms of the GNU Lesser General Public License as published by the Free #
29
+ # Software Foundation, either version 3 of the License, or (at your option) #
30
+ # any later version. #
31
+ # #
32
+ # PyGithub is distributed in the hope that it will be useful, but WITHOUT ANY #
33
+ # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS #
34
+ # FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more #
35
+ # details. #
36
+ # #
37
+ # You should have received a copy of the GNU Lesser General Public License #
38
+ # along with PyGithub. If not, see <http://www.gnu.org/licenses/>. #
39
+ # #
40
+ ################################################################################
41
+
42
+ from __future__ import annotations
43
+
44
+ from datetime import datetime
45
+ from typing import Any
46
+
47
+ from githubasyncio.GithubObject import Attribute, NonCompletableGithubObject, NotSet
48
+
49
+
50
+ class Topic(NonCompletableGithubObject):
51
+ """
52
+ This class represents topics as used by https://github.com/topics. The object reference can be found here https://docs.github.com/en/rest/reference/search#search-topics
53
+
54
+ The OpenAPI schema can be found at
55
+
56
+ - /components/schemas/topic-search-result-item
57
+
58
+ """
59
+
60
+ def _initAttributes(self) -> None:
61
+ self._aliases: Attribute[list[dict[str, Any]]] = NotSet
62
+ self._created_at: Attribute[datetime] = NotSet
63
+ self._created_by: Attribute[str] = NotSet
64
+ self._curated: Attribute[bool] = NotSet
65
+ self._description: Attribute[str] = NotSet
66
+ self._display_name: Attribute[str] = NotSet
67
+ self._featured: Attribute[bool] = NotSet
68
+ self._logo_url: Attribute[str] = NotSet
69
+ self._name: Attribute[str] = NotSet
70
+ self._related: Attribute[list[dict[str, Any]]] = NotSet
71
+ self._released: Attribute[str] = NotSet
72
+ self._repository_count: Attribute[int] = NotSet
73
+ self._score: Attribute[float] = NotSet
74
+ self._short_description: Attribute[str] = NotSet
75
+ self._text_matches: Attribute[dict[str, Any]] = NotSet
76
+ self._updated_at: Attribute[datetime] = NotSet
77
+
78
+ def __repr__(self) -> str:
79
+ return self.get__repr__({"name": self._name.value})
80
+
81
+ @property
82
+ def aliases(self) -> list[dict[str, Any]]:
83
+ return self._aliases.value
84
+
85
+ @property
86
+ def created_at(self) -> datetime:
87
+ return self._created_at.value
88
+
89
+ @property
90
+ def created_by(self) -> str:
91
+ return self._created_by.value
92
+
93
+ @property
94
+ def curated(self) -> bool:
95
+ return self._curated.value
96
+
97
+ @property
98
+ def description(self) -> str:
99
+ return self._description.value
100
+
101
+ @property
102
+ def display_name(self) -> str:
103
+ return self._display_name.value
104
+
105
+ @property
106
+ def featured(self) -> bool:
107
+ return self._featured.value
108
+
109
+ @property
110
+ def logo_url(self) -> str:
111
+ return self._logo_url.value
112
+
113
+ @property
114
+ def name(self) -> str:
115
+ return self._name.value
116
+
117
+ @property
118
+ def related(self) -> list[dict[str, Any]]:
119
+ return self._related.value
120
+
121
+ @property
122
+ def released(self) -> str:
123
+ return self._released.value
124
+
125
+ @property
126
+ def repository_count(self) -> int:
127
+ return self._repository_count.value
128
+
129
+ @property
130
+ def score(self) -> float:
131
+ return self._score.value
132
+
133
+ @property
134
+ def short_description(self) -> str:
135
+ return self._short_description.value
136
+
137
+ @property
138
+ def text_matches(self) -> dict[str, Any]:
139
+ return self._text_matches.value
140
+
141
+ @property
142
+ def updated_at(self) -> datetime:
143
+ return self._updated_at.value
144
+
145
+ def _useAttributes(self, attributes: dict[str, Any]) -> None:
146
+ if "aliases" in attributes: # pragma no branch
147
+ self._aliases = self._makeListOfDictsAttribute(attributes["aliases"])
148
+ if "created_at" in attributes: # pragma no branch
149
+ self._created_at = self._makeDatetimeAttribute(attributes["created_at"])
150
+ if "created_by" in attributes: # pragma no branch
151
+ self._created_by = self._makeStringAttribute(attributes["created_by"])
152
+ if "curated" in attributes: # pragma no branch
153
+ self._curated = self._makeBoolAttribute(attributes["curated"])
154
+ if "description" in attributes: # pragma no branch
155
+ self._description = self._makeStringAttribute(attributes["description"])
156
+ if "display_name" in attributes: # pragma no branch
157
+ self._display_name = self._makeStringAttribute(attributes["display_name"])
158
+ if "featured" in attributes: # pragma no branch
159
+ self._featured = self._makeBoolAttribute(attributes["featured"])
160
+ if "logo_url" in attributes: # pragma no branch
161
+ self._logo_url = self._makeStringAttribute(attributes["logo_url"])
162
+ if "name" in attributes: # pragma no branch
163
+ self._name = self._makeStringAttribute(attributes["name"])
164
+ if "related" in attributes: # pragma no branch
165
+ self._related = self._makeListOfDictsAttribute(attributes["related"])
166
+ if "released" in attributes: # pragma no branch
167
+ self._released = self._makeStringAttribute(attributes["released"])
168
+ if "repository_count" in attributes: # pragma no branch
169
+ self._repository_count = self._makeIntAttribute(attributes["repository_count"])
170
+ if "score" in attributes: # pragma no branch
171
+ self._score = self._makeFloatAttribute(attributes["score"])
172
+ if "short_description" in attributes: # pragma no branch
173
+ self._short_description = self._makeStringAttribute(attributes["short_description"])
174
+ if "text_matches" in attributes: # pragma no branch
175
+ self._text_matches = self._makeDictAttribute(attributes["text_matches"])
176
+ if "updated_at" in attributes: # pragma no branch
177
+ self._updated_at = self._makeDatetimeAttribute(attributes["updated_at"])
@@ -0,0 +1,95 @@
1
+ # FILE AUTO GENERATED DO NOT TOUCH
2
+ ############################ Copyrights and license ############################
3
+ # #
4
+ # Copyright 2012 Vincent Jacques <vincent@vincent-jacques.net> #
5
+ # Copyright 2012 Zearin <zearin@gonk.net> #
6
+ # Copyright 2013 AKFish <akfish@gmail.com> #
7
+ # Copyright 2013 Vincent Jacques <vincent@vincent-jacques.net> #
8
+ # Copyright 2014 Vincent Jacques <vincent@vincent-jacques.net> #
9
+ # Copyright 2016 Jannis Gebauer <ja.geb@me.com> #
10
+ # Copyright 2016 Peter Buckley <dx-pbuckley@users.noreply.github.com> #
11
+ # Copyright 2018 Justin Kufro <jkufro@andrew.cmu.edu> #
12
+ # Copyright 2018 Wan Liuyang <tsfdye@gmail.com> #
13
+ # Copyright 2018 sfdye <tsfdye@gmail.com> #
14
+ # Copyright 2019 Steve Kowalik <steven@wedontsleep.org> #
15
+ # Copyright 2019 Wan Liuyang <tsfdye@gmail.com> #
16
+ # Copyright 2020 Steve Kowalik <steven@wedontsleep.org> #
17
+ # Copyright 2021 Steve Kowalik <steven@wedontsleep.org> #
18
+ # Copyright 2023 Enrico Minack <github@enrico.minack.dev> #
19
+ # Copyright 2023 Trim21 <trim21.me@gmail.com> #
20
+ # Copyright 2024 Enrico Minack <github@enrico.minack.dev> #
21
+ # Copyright 2024 Jirka Borovec <6035284+Borda@users.noreply.github.com> #
22
+ # Copyright 2025 Enrico Minack <github@enrico.minack.dev> #
23
+ # #
24
+ # This file is part of PyGithub. #
25
+ # http://pygithub.readthedocs.io/ #
26
+ # #
27
+ # PyGithub is free software: you can redistribute it and/or modify it under #
28
+ # the terms of the GNU Lesser General Public License as published by the Free #
29
+ # Software Foundation, either version 3 of the License, or (at your option) #
30
+ # any later version. #
31
+ # #
32
+ # PyGithub is distributed in the hope that it will be useful, but WITHOUT ANY #
33
+ # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS #
34
+ # FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more #
35
+ # details. #
36
+ # #
37
+ # You should have received a copy of the GNU Lesser General Public License #
38
+ # along with PyGithub. If not, see <http://www.gnu.org/licenses/>. #
39
+ # #
40
+ ################################################################################
41
+
42
+ from __future__ import annotations
43
+
44
+ from datetime import datetime
45
+ from typing import Any
46
+
47
+ from githubasyncio.GithubObject import Attribute, NonCompletableGithubObject, NotSet
48
+
49
+
50
+ class Traffic(NonCompletableGithubObject):
51
+ """
52
+ This class represents traffic information at a specific point in time.
53
+
54
+ The reference can be found here
55
+ https://docs.github.com/en/rest/metrics/traffic
56
+
57
+ The OpenAPI schema can be found at
58
+
59
+ - /components/schemas/traffic
60
+
61
+ """
62
+
63
+ def _initAttributes(self) -> None:
64
+ self._count: Attribute[int] = NotSet
65
+ self._timestamp: Attribute[datetime] = NotSet
66
+ self._uniques: Attribute[int] = NotSet
67
+
68
+ def __repr__(self) -> str:
69
+ return self.get__repr__(
70
+ {
71
+ "timestamp": self._timestamp.value,
72
+ "count": self._count.value,
73
+ "uniques": self._uniques.value,
74
+ }
75
+ )
76
+
77
+ @property
78
+ def count(self) -> int:
79
+ return self._count.value
80
+
81
+ @property
82
+ def timestamp(self) -> datetime:
83
+ return self._timestamp.value
84
+
85
+ @property
86
+ def uniques(self) -> int:
87
+ return self._uniques.value
88
+
89
+ def _useAttributes(self, attributes: dict[str, Any]) -> None:
90
+ if "count" in attributes: # pragma no branch
91
+ self._count = self._makeIntAttribute(attributes["count"])
92
+ if "timestamp" in attributes: # pragma no branch
93
+ self._timestamp = self._makeDatetimeAttribute(attributes["timestamp"])
94
+ if "uniques" in attributes: # pragma no branch
95
+ self._uniques = self._makeIntAttribute(attributes["uniques"])