Add support for Telegram Bot API 9.1#1704
Merged
JrooTJunior merged 4 commits intodev-3.xfrom Jul 5, 2025
Merged
Conversation
…gifts, and new methods like `SendChecklist`, `EditMessageChecklist`, and `GetMyStarBalance`. Update changelog and improve `True` field descriptions.
✔️ Changelog found.Thank you for adding a description of the changes |
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds full support for Telegram Bot API 9.1, introducing checklist types/methods, gift resale fields, and a new star‐balance endpoint.
- Adds
Checklistand related types plussend_checklist/edit_message_checklistmethods. - Adds
last_resale_star_count,next_transfer_date, and updatesoriginin gift types. - Introduces
GetMyStarBalancemethod and raises poll options limit to 12.
Reviewed Changes
Copilot reviewed 111 out of 112 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| aiogram/types/checklist.py | New Checklist type and imports |
| aiogram/types/input_checklist.py | New InputChecklist type |
| aiogram/types/input_checklist_task.py | New InputChecklistTask type |
| aiogram/types/checklist_task.py | New ChecklistTask type |
| aiogram/types/checklist_tasks_added.py | New ChecklistTasksAdded type |
| aiogram/types/checklist_tasks_done.py | New ChecklistTasksDone type |
| aiogram/types/direct_message_price_changed.py | New DirectMessagePriceChanged type |
| aiogram/types/unique_gift_info.py | Added gift resale fields |
| aiogram/types/owned_gift_unique.py / owned_gift_regular.py | Added next_transfer_date fields |
| aiogram/types/message.py | Added checklist/service‐message fields |
| aiogram/enums/content_type.py | Added new content types |
| aiogram/methods/send_checklist.py | New SendChecklist method |
| aiogram/methods/edit_message_checklist.py | New EditMessageChecklist method |
| aiogram/methods/get_my_star_balance.py | New GetMyStarBalance method |
| aiogram/client/bot.py | Exposed new methods on Bot |
| tests/test_api/test_methods/test_send_checklist.py | Basic test for send_checklist |
| tests/test_api/test_methods/test_edit_message_checklist.py | Basic test for edit_message_checklist |
| tests/test_api/test_methods/test_get_my_star_balance.py | Basic test for get_my_star_balance |
| tests/test_api/test_types/test_message.py | Added checklist and direct‐message tests |
Comments suppressed due to low confidence (3)
tests/test_api/test_methods/test_send_checklist.py:33
- Consider adding assertions on the
request.methodandrequest.payload["checklist"]to verify thatSendChecklistis serialized correctly in the API request.
request = bot.get_request()
tests/test_api/test_methods/test_edit_message_checklist.py:35
- It may be beneficial to assert
bot.get_request()contents (method name and payload fields) to ensureEditMessageChecklistparameters are passed correctly.
assert response == prepare_result.result
tests/test_api/test_methods/test_get_my_star_balance.py:18
- Consider adding an assertion for
request.methodfrombot.get_request()to verify that theGetMyStarBalancecall is constructed as expected.
assert response == prepare_result.result
…tead of hardcoded literals
…nd webhook server classes
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## dev-3.x #1704 +/- ##
==========================================
Coverage 100.00% 100.00%
==========================================
Files 568 578 +10
Lines 13351 13531 +180
==========================================
+ Hits 13351 13531 +180
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add support for Telegram Bot API 9.1 features, including checklists, gifts, and new methods like
SendChecklist,EditMessageChecklist, andGetMyStarBalance. Update changelog.Bot API Changelog